Przeglądaj źródła

Make the default action for the gitea executable that of running the webserver (#3331)

tags/v1.4.0-rc1
Morgan Bazalgette 6 lat temu
rodzic
commit
88a3bb6d42
1 zmienionych plików z 3 dodań i 0 usunięć
  1. 3
    0
      main.go

+ 3
- 0
main.go Wyświetl plik

app := cli.NewApp() app := cli.NewApp()
app.Name = "Gitea" app.Name = "Gitea"
app.Usage = "A painless self-hosted Git service" app.Usage = "A painless self-hosted Git service"
app.Description = `By default, gitea will start serving using the webserver with no
arguments - which can alternatively be run by running the subcommand web.`
app.Version = Version + formatBuiltWith(Tags) app.Version = Version + formatBuiltWith(Tags)
app.Commands = []cli.Command{ app.Commands = []cli.Command{
cmd.CmdWeb, cmd.CmdWeb,
cmd.CmdAdmin, cmd.CmdAdmin,
} }
app.Flags = append(app.Flags, []cli.Flag{}...) app.Flags = append(app.Flags, []cli.Flag{}...)
app.Action = cmd.CmdWeb.Action
err := app.Run(os.Args) err := app.Run(os.Args)
if err != nil { if err != nil {
log.Fatal(4, "Failed to run app with %s: %v", os.Args, err) log.Fatal(4, "Failed to run app with %s: %v", os.Args, err)

Ładowanie…
Anuluj
Zapisz