gitx
gitx copied to clipboard
Tags should be shown in reverse alphabetical order (~newest at top)
atm, the order is 0.1 1.5 etc...
should be 1.5 0.1 at the bottom
that would be nice :)
Currently it is being sorted alphanumerically. If it's changed to reverse the sort then tags with letters will be reversed. And if number only tags are reversed how should tags like "v0.1" be dealt with?
very good point. I guess there's no "datestamp" associated with tags? Newest first? - If there isn't, I suppose you could look at the date of the commit that the tag points to?
Annotated tags have a date but regular ones don't. But maybe looking at the commit would work.
I would suggest displaying all annotated tags, sorted by tag object date. Then after that, display all non-annotated tags, sorted lexicographically.
At first I liked this idea, but after some thought I don't anymore.
I think the current sort is correct. It's the whole point of semantic versioning "Precedence SHOULD be determined by lexicographic ASCII sort order" because that order is the default behavior everywhere. Reversing it is not a standard, just a common practice for those using semantic versioning.
However, not everybody uses semantic versioning. Having tags sort the way everything else on a computer sorts is predictable so you don't break somebody else's tagging structure.
Sorting by two lists (annotated and non-annotated) would become a mess for some of our repositories where some devs are new to git and don't annotate their tags.