moving run command
- run command is no longer attached to the 'command' subcmd - run is standalone
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
||||
"fmt"
|
||||
"os"
|
||||
|
||||
"code.jakeyoungdev.com/jake/mctl/constants"
|
||||
"code.jakeyoungdev.com/jake/mctl/database"
|
||||
"github.com/spf13/cobra"
|
||||
)
|
||||
@@ -42,8 +43,8 @@ var addCmd = &cobra.Command{
|
||||
|
||||
err = db.SaveCmd(cfgname, cfgcmd)
|
||||
if err != nil {
|
||||
if err.Error() == ErrInit {
|
||||
fmt.Println(ErrInitRsp)
|
||||
if err.Error() == constants.ErrInit {
|
||||
fmt.Println(constants.ErrInitRsp)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user