Command-line tool to sort git annotated N-V-R named tags, which have been merged, by topological sort (primary criterion) and rpm version-release sort (secondary criterion).

Example on prunerepo repository (includes also example output that might differ from what you obtain):

$ git clone https://pagure.io/prunerepo
$ cd prunerepo
$ rpm-git-tag-sort prunerepo .
5bc7a947df0eda2d70f61574f3c45812c2a01af prunerepo-1.19-1
046256b8e31492fa2f823f909aafb931ca91f79 prunerepo-1.18-1
ced28a4bc04baac380fdade4e746356d702523b prunerepo-1.17-1
1e550ed55a13923920d42c5534e93aefd6cbfa9 prunerepo-1.16-1

See rpm-git-tag-sort --help for more info about usage.