]> source.dussan.org Git - gitea.git/commitdiff
Move custom dir to custom/
authorUnknown <joe2010xtmf@163.com>
Thu, 13 Mar 2014 01:40:18 +0000 (21:40 -0400)
committerUnknown <joe2010xtmf@163.com>
Thu, 13 Mar 2014 01:40:18 +0000 (21:40 -0400)
.gitignore
modules/base/conf.go
serve.go

index 49d19b83d0aac8ff62300303839c69c43c8a5010..0323c29726df8bef57a54979792b0d2f65c23168 100644 (file)
@@ -4,4 +4,4 @@ gogs
 .DS_Store
 *.db
 *.log
-conf/custom.ini
\ No newline at end of file
+custom/
\ No newline at end of file
index 1240448c10a2eb563991cf4f834e713378aa79b5..809b2b8c18a19a33a752176eadf983a3b0950934 100644 (file)
@@ -37,15 +37,14 @@ func init() {
                os.Exit(2)
        }
 
-       cfgPathPrefix := filepath.Join(workDir, "conf")
-       cfgPath := filepath.Join(cfgPathPrefix, "app.ini")
+       cfgPath := filepath.Join(workDir, "conf/app.ini")
        Cfg, err = goconfig.LoadConfigFile(cfgPath)
        if err != nil {
                fmt.Printf("Cannot load config file '%s'\n", cfgPath)
                os.Exit(2)
        }
 
-       cfgPath = filepath.Join(cfgPathPrefix, "custom.ini")
+       cfgPath = filepath.Join(workDir, "custom/conf/app.ini")
        if com.IsFile(cfgPath) {
                if err = Cfg.AppendFiles(cfgPath); err != nil {
                        fmt.Printf("Cannot load config file '%s'\n", cfgPath)
index d4874b3ed629094a489b97839ab8c483d91b3828..97b9c567e6d36a26fd7b7dfec194069f48af0adc 100644 (file)
--- a/serve.go
+++ b/serve.go
@@ -58,7 +58,7 @@ func runServ(*cli.Context) {
 
        cmd := os.Getenv("SSH_ORIGINAL_COMMAND")
        if cmd == "" {
-               printf("Hi %s! You've successfully authenticated, but Gogs does not provide shell access.\n", user.Name)
+               fmt.Printf("Hi %s! You've successfully authenticated, but Gogs does not provide shell access.\n", user.Name)
                return
        }