Rename gitea to forge in cli args and env variables (#339)

This PR renames `gitea` in cli args to `forge` and `GITEA` in environment variables to `FORGE` and adds the gitea names as aliases for the forge names.

Also closes #311

Reviewed-on: https://codeberg.org/Codeberg/pages-server/pulls/339
This commit is contained in:
crapStone 2024-05-26 14:45:03 +00:00
parent eea009c7fe
commit 77a8439ea7
9 changed files with 81 additions and 51 deletions

View file

@ -77,7 +77,7 @@ func Serve(ctx *cli.Context) error {
// clientResponseCache stores responses from the Gitea server
clientResponseCache := cache.NewInMemoryCache()
giteaClient, err := gitea.NewClient(cfg.Gitea, clientResponseCache)
giteaClient, err := gitea.NewClient(cfg.Forge, clientResponseCache)
if err != nil {
return fmt.Errorf("could not create new gitea client: %v", err)
}