diff --git a/main.go b/main.go index aa98ea8..c6bd8aa 100644 --- a/main.go +++ b/main.go @@ -64,6 +64,7 @@ func main() { Action: func(params *cli.Context) error { y := realize.Config{} err := y.Read() + y.Add(params) return handle(err) }, }, diff --git a/realize/config.go b/realize/config.go index 0c30e3f..40ff7c9 100644 --- a/realize/config.go +++ b/realize/config.go @@ -92,14 +92,15 @@ func (h *Config) Create() error{ // Add another project func (h *Config) Add(params *cli.Context) { - //new := Project{ - // Main: params.String("main"), - // Run: params.Bool("run"), - // Build: params.Bool("build"), - // Watcher: Watcher{ - // Paths: []string{"/"}, - // Exts: []string{"go"}, - // }, - //} + new := Project{ + Main: params.String("main"), + Run: params.Bool("run"), + Build: params.Bool("build"), + Watcher: Watcher{ + Paths: []string{"/"}, + Exts: []string{"go"}, + }, + } + h.Projects = append(h.Projects, new) }