We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9c8c1e1 commit 72e7e28Copy full SHA for 72e7e28
1 file changed
cmd/sort.go
@@ -63,12 +63,8 @@ func RunSort(cmd *cobra.Command, args []string) error {
63
versions = filtered
64
}
65
66
- ascending := true
67
- // Sort versions
68
- if order == "descending" || order == "dsc" {
69
- // Sort in descending order
70
- ascending = false
71
- }
+ ascending := order == "ascending" || order == "asc"
+
72
sort.SortVersions(semver.Collection(versions), ascending)
73
74
result := VersionsToStrings(versions)
0 commit comments