diff options
author | Unknown <joe2010xtmf@163.com> | 2014-03-16 02:28:24 -0400 |
---|---|---|
committer | Unknown <joe2010xtmf@163.com> | 2014-03-16 02:28:24 -0400 |
commit | 828c89de996c328bb3759d90be8a8a35b4d9cdc0 (patch) | |
tree | bc0c01f6fb9905892439e8b0eb3aaa76cd01eacf /gogs.go | |
parent | 631deb2e7d52d474469382c497878bde9083cb60 (diff) | |
download | gitea-828c89de996c328bb3759d90be8a8a35b4d9cdc0.tar.gz gitea-828c89de996c328bb3759d90be8a8a35b4d9cdc0.zip |
Clean code
Diffstat (limited to 'gogs.go')
-rw-r--r-- | gogs.go | 22 |
1 files changed, 10 insertions, 12 deletions
@@ -7,7 +7,7 @@ package main import ( "os" - "os/user" + // "os/user" "runtime" "github.com/codegangsta/cli" @@ -27,14 +27,14 @@ func init() { runtime.GOMAXPROCS(runtime.NumCPU()) } -func checkRunUser() bool { - u, err := user.Current() - if err != nil { - // TODO: log - return false - } - return u.Username == base.Cfg.MustValue("", "RUN_USER") -} +// func checkRunUser() bool { +// u, err := user.Current() +// if err != nil { +// // TODO: log +// return false +// } +// return u.Username == base.Cfg.MustValue("", "RUN_USER") +// } func main() { /*if !checkRunUser() { @@ -50,8 +50,6 @@ func main() { CmdWeb, CmdServ, } - app.Flags = append(app.Flags, []cli.Flag{ - cli.BoolFlag{"noterm", "disable color output"}, - }...) + app.Flags = append(app.Flags, []cli.Flag{}...) app.Run(os.Args) } |