all repos — elgit @ 6620eb3e6bc59b195ca72b3f14f22fbc5c7a4aec

fork of legit: web frontend for git, written in go

watch projects.list and reload on changes

Alan Pearce
commit

6620eb3e6bc59b195ca72b3f14f22fbc5c7a4aec

parent

c541f419c0283487d7244a74899fa2d023b12a07

1 file changed, 2 insertions(+), 3 deletions(-)

changed files
M routes/util.goroutes/util.go
@@ -11,7 +11,6 @@ "strings"
securejoin "github.com/cyphar/filepath-securejoin" "github.com/dimfeld/httptreemux/v5" - "go.alanpearce.eu/elgit/config" "go.alanpearce.eu/elgit/data" "go.alanpearce.eu/elgit/git" )
@@ -50,8 +49,8 @@ httptreemux.Clean(name)+".git",
) } -func ReadProjectsList(c *config.Config) ([]string, error) { - content, err := os.ReadFile(filepath.Join(c.Repo.Root, "projects.list")) +func ReadProjectsList(filename string) ([]string, error) { + content, err := os.ReadFile(filename) if err != nil { return nil, err }