Remove caching
I removed this because it was making tests fail!
This commit is contained in:
parent
9e97712956
commit
b69dff172c
1 changed files with 0 additions and 7 deletions
|
|
@ -10,13 +10,7 @@ import (
|
|||
"strings"
|
||||
)
|
||||
|
||||
var cachedDir string
|
||||
|
||||
func Dir() (string, error) {
|
||||
if cachedDir != "" {
|
||||
return cachedDir, nil
|
||||
}
|
||||
|
||||
dirCmd := exec.Command("git", "rev-parse", "-q", "--git-dir")
|
||||
dirCmd.Stderr = nil
|
||||
output, err := dirCmd.Output()
|
||||
|
|
@ -33,7 +27,6 @@ func Dir() (string, error) {
|
|||
gitDir = filepath.Clean(gitDir)
|
||||
}
|
||||
|
||||
cachedDir = gitDir
|
||||
return gitDir, nil
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue