@@ -976,7 +976,7 @@ func (a *App) runClusterList(ctx context.Context, command string, args []string,
976976 fs .SetOutput (io .Discard )
977977 minSizeRaw := fs .String ("min-size" , "" , "minimum active member count" )
978978 limitRaw := fs .String ("limit" , "" , "maximum cluster rows" )
979- sortMode := fs .String ("sort" , "size" , "sort mode: recent|size" )
979+ sortMode := fs .String ("sort" , "size" , "sort mode: recent|oldest| size" )
980980 includeClosed := fs .Bool ("include-closed" , false , "deprecated; clusters include closed rows by default" )
981981 hideClosed := fs .Bool ("hide-closed" , false , "hide locally closed clusters" )
982982 jsonOut := fs .Bool ("json" , false , "write JSON output" )
@@ -1000,7 +1000,7 @@ func (a *App) runClusterList(ctx context.Context, command string, args []string,
10001000 return usageErr (err )
10011001 }
10021002 sort := strings .TrimSpace (* sortMode )
1003- if sort != "recent" && sort != "size" {
1003+ if sort != "recent" && sort != "oldest" && sort != " size" {
10041004 return usageErr (fmt .Errorf ("unsupported sort %q" , sort ))
10051005 }
10061006
@@ -1040,7 +1040,7 @@ func (a *App) runTUI(ctx context.Context, args []string) error {
10401040 fs .SetOutput (io .Discard )
10411041 minSizeRaw := fs .String ("min-size" , "" , "minimum active member count" )
10421042 limitRaw := fs .String ("limit" , "" , "maximum cluster rows" )
1043- sortMode := fs .String ("sort" , "" , "sort mode: recent|size" )
1043+ sortMode := fs .String ("sort" , "" , "sort mode: recent|oldest| size" )
10441044 includeClosed := fs .Bool ("include-closed" , false , "deprecated; closed clusters are shown by default" )
10451045 hideClosed := fs .Bool ("hide-closed" , false , "hide locally closed clusters" )
10461046 jsonOut := fs .Bool ("json" , false , "write JSON output" )
@@ -1090,7 +1090,7 @@ func (a *App) runTUI(ctx context.Context, args []string) error {
10901090 if sort == "" {
10911091 sort = "size"
10921092 }
1093- if sort != "recent" && sort != "size" {
1093+ if sort != "recent" && sort != "oldest" && sort != " size" {
10941094 return usageErr (fmt .Errorf ("unsupported sort %q" , sort ))
10951095 }
10961096 showClosed := ! * hideClosed || * includeClosed
@@ -2707,7 +2707,7 @@ No API server is provided. There is intentionally no serve command.
27072707const tuiUsageText = `gitcrawl tui opens the local terminal cluster browser.
27082708
27092709Usage:
2710- gitcrawl tui [owner/repo] [--limit N] [--min-size N] [--sort recent|size] [--hide-closed]
2710+ gitcrawl tui [owner/repo] [--limit N] [--min-size N] [--sort recent|oldest| size] [--hide-closed]
27112711
27122712If owner/repo is omitted, gitcrawl uses the most recently updated repository in the local database.
27132713The TUI starts with ghcrawl-style cluster display defaults: --min-size 5, --sort size, and closed historical clusters visible. Pass --min-size 1 for singleton clusters or --hide-closed to focus open-only.
0 commit comments