1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2025-08-31 18:30:57 +00:00

Merge remote-tracking branch 'forgejo/forgejo-branding' into forgejo

This commit is contained in:
Earl Warren 2023-05-16 15:03:59 +02:00
commit bf022834f9
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00
78 changed files with 993 additions and 229 deletions

18
main.go
View file

@ -50,11 +50,20 @@ func init() {
originalSubcommandHelpTemplate = cli.SubcommandHelpTemplate
}
func forgejoEnv() {
for _, k := range []string{"CUSTOM", "WORK_DIR"} {
if v, ok := os.LookupEnv("FORGEJO_" + k); ok {
os.Setenv("GITEA_"+k, v)
}
}
}
func main() {
forgejoEnv()
app := cli.NewApp()
app.Name = "Gitea"
app.Usage = "A painless self-hosted Git service"
app.Description = `By default, gitea will start serving using the webserver with no
app.Name = "Forgejo"
app.Usage = "Beyond coding. We forge."
app.Description = `By default, forgejo will start serving using the webserver with no
arguments - which can alternatively be run by running the subcommand web.`
app.Version = Version + formatBuiltWith()
app.Commands = []cli.Command{
@ -179,6 +188,9 @@ func adjustHelpTemplate(originalTemplate string) string {
if _, ok := os.LookupEnv("GITEA_CUSTOM"); ok {
overridden = "(GITEA_CUSTOM)"
}
if _, ok := os.LookupEnv("FORGEJO_CUSTOM"); ok {
overridden = "(FORGEJO_CUSTOM)"
}
return fmt.Sprintf(`%s
DEFAULT CONFIGURATION: