Fix bugs, set constants
This commit is contained in:
7
internal/cache/projects_fs.go
vendored
7
internal/cache/projects_fs.go
vendored
@@ -48,14 +48,11 @@ func (c *Cache) GetProjectFromCwd() (*projects.Project, error) {
|
||||
|
||||
func (c *Cache) IsProjectCloned(p *projects.Project) bool {
|
||||
_, err := os.Stat(c.GetProjectPath(p) + "/.git")
|
||||
if err == nil {
|
||||
return true
|
||||
}
|
||||
return false
|
||||
return err == nil
|
||||
}
|
||||
|
||||
func (c *Cache) PrepProjectPath(path string) {
|
||||
if err := os.MkdirAll(path, 0750); err != nil {
|
||||
if err := os.MkdirAll(path, 0o750); err != nil {
|
||||
c.log.Fatal("Failed to prepare project path", c.log.Args(
|
||||
"path", path,
|
||||
"error", err,
|
||||
|
||||
Reference in New Issue
Block a user