feat: github adapter

This commit is contained in:
2025-02-24 21:48:16 +01:00
parent 5606e658a2
commit 20790b04b3
7 changed files with 386 additions and 38 deletions

View File

@ -6,6 +6,7 @@ import (
"log/slog"
"path/filepath"
"regexp"
"slices"
"strings"
"time"
@ -72,6 +73,10 @@ func (m *IssueManager) GetUserProjects(ctx context.Context, user *model.User) ([
return nil, errors.WithStack(err)
}
slices.SortFunc(refreshedProjects, func(p1 *model.Project, p2 *model.Project) int {
return strings.Compare(p1.Name, p2.Name)
})
m.projectCache.Set(cacheKey, refreshedProjects, 0)
projects = refreshedProjects