diff options
Diffstat (limited to 'gitConfig.go')
| -rw-r--r-- | gitConfig.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gitConfig.go b/gitConfig.go index ce8834c..595345f 100644 --- a/gitConfig.go +++ b/gitConfig.go @@ -2,6 +2,7 @@ package repostatus import ( "bufio" + "errors" "os" "path/filepath" "strings" @@ -84,8 +85,7 @@ func (rs *RepoStatus) readGitConfig() error { log.Log(WARN, "readGitConfig() trying up one directory instead", filename) file, err = os.Open(filename) if err != nil { - panic("couldn't open .git/config") - return nil + return errors.New("couldn't open .git/config") } } defer file.Close() |
