Code git descriptor to a string
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | descriptor |
pure function descriptor_name(descriptor) result(name) integer, intent(in) :: descriptor character(len=:), allocatable :: name select case (descriptor) case (git_descriptor%default); name = "default" case (git_descriptor%branch); name = "branch" case (git_descriptor%tag); name = "tag" case (git_descriptor%revision); name = "revision" case default; name = "ERROR" end select end function descriptor_name