added sort

This commit is contained in:
elee 2022-03-03 23:41:28 -06:00
parent 60b32441ef
commit e6f0611ee3
1 changed files with 7 additions and 0 deletions

View File

@ -22,6 +22,7 @@ import (
"net" "net"
"net/http" "net/http"
"regexp" "regexp"
"sort"
"strconv" "strconv"
"strings" "strings"
"time" "time"
@ -317,6 +318,12 @@ func (c *Client) listUserRepos(fromOptions gitlab.ListProjectsOptions) ([]*gitso
} }
} }
sort.Slice(repos, func(i, j int) bool {
a := repos[i]
b := repos[j]
return a.Path < b.Path
})
return repos, nil return repos, nil
} }