all: Propagate baseURL error to the callers

This commit is contained in:
Bjørn Erik Pedersen
2017-03-25 14:37:04 +01:00
parent 148fedd227
commit 15b64d51da
18 changed files with 124 additions and 47 deletions

View File

@@ -118,7 +118,10 @@ Complete documentation is available at http://gohugo.io/.`,
return err
}
c := newCommandeer(cfg)
c, err := newCommandeer(cfg)
if err != nil {
return err
}
if buildWatch {
cfg.Cfg.Set("disableLiveReload", true)
@@ -287,7 +290,10 @@ func InitializeConfig(subCmdVs ...*cobra.Command) (*deps.DepsCfg, error) {
cfg.Cfg = config
c := newCommandeer(cfg)
c, err := newCommandeer(cfg)
if err != nil {
return nil, err
}
for _, cmdV := range append([]*cobra.Command{hugoCmdV}, subCmdVs...) {
c.initializeFlags(cmdV)