code review
This commit is contained in:
parent
bccfaca01d
commit
b7c50a2efb
10
realize.go
10
realize.go
@ -130,17 +130,17 @@ func main() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if p.Bool("legacy") {
|
if p.Bool("legacy") {
|
||||||
r.Config.Legacy = settings.Legacy{
|
c.Config.Legacy = settings.Legacy{
|
||||||
Status: p.Bool("legacy"),
|
Status: p.Bool("legacy"),
|
||||||
Interval: interval,
|
Interval: interval,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if p.Bool("no-config") || len(r.Blueprint.Projects) <= 0 {
|
if p.Bool("no-config") || len(c.Blueprint.Projects) <= 0 {
|
||||||
if p.Bool("no-config") {
|
if p.Bool("no-config") {
|
||||||
r.Config.Create = false
|
c.Config.Create = false
|
||||||
}
|
}
|
||||||
r.Blueprint.Projects = []watcher.Project{}
|
c.Blueprint.Projects = []watcher.Project{}
|
||||||
if err := r.Blueprint.Add(p); err != nil {
|
if err := c.Blueprint.Add(p); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
package settings
|
package settings
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
yaml "gopkg.in/yaml.v2"
|
||||||
"os"
|
"os"
|
||||||
"time"
|
"time"
|
||||||
yaml "gopkg.in/yaml.v2"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
var Dir = ".realize/"
|
var Dir = ".realize/"
|
||||||
|
|||||||
@ -178,5 +178,5 @@ func (h *Blueprint) check() error {
|
|||||||
h.Clean()
|
h.Clean()
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
return errors.New("there are no projects")
|
return errors.New("There are no projects")
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user