rename gitea to forge for cli and add gitea options as aliases

This commit is contained in:
crapStone 2024-05-19 23:53:50 +02:00
parent 9ce901bfa0
commit 5cac5e105c
No known key found for this signature in database
GPG key ID: 22D4BF0CF7CC29C8
6 changed files with 73 additions and 44 deletions

View file

@ -22,29 +22,31 @@ var (
ServerFlags = append(CertStorageFlags, []cli.Flag{
// #############
// ### Gitea ###
// ### Forge ###
// #############
// GiteaRoot specifies the root URL of the Gitea instance, without a trailing slash.
// ForgeRoot specifies the root URL of the Forge instance, without a trailing slash.
&cli.StringFlag{
Name: "gitea-root",
Usage: "specifies the root URL of the Gitea instance, without a trailing slash.",
EnvVars: []string{"GITEA_ROOT"},
Name: "forge-root",
Aliases: []string{"gitea-root"},
Usage: "specifies the root URL of the Forgejo/Gitea instance, without a trailing slash.",
EnvVars: []string{"FORGE_ROOT", "GITEA_ROOT"},
},
// GiteaApiToken specifies an api token for the Gitea instance
// ForgeApiToken specifies an api token for the Forge instance
&cli.StringFlag{
Name: "gitea-api-token",
Usage: "specifies an api token for the Gitea instance",
EnvVars: []string{"GITEA_API_TOKEN"},
Name: "forge-api-token",
Aliases: []string{"gitea-api-token"},
Usage: "specifies an api token for the Forgejo/Gitea instance",
EnvVars: []string{"FORGE_API_TOKEN", "GITEA_API_TOKEN"},
},
&cli.BoolFlag{
Name: "enable-lfs-support",
Usage: "enable lfs support, require gitea >= v1.17.0 as backend",
Usage: "enable lfs support, gitea must be version v1.17.0 or higher",
EnvVars: []string{"ENABLE_LFS_SUPPORT"},
Value: false,
},
&cli.BoolFlag{
Name: "enable-symlink-support",
Usage: "follow symlinks if enabled, require gitea >= v1.18.0 as backend",
Usage: "follow symlinks if enabled, gitea must be version v1.18.0 or higher",
EnvVars: []string{"ENABLE_SYMLINK_SUPPORT"},
Value: false,
},