Skip to content

Commit

Permalink
fix(configure): configure command creates correct file now
Browse files Browse the repository at this point in the history
  • Loading branch information
hef committed Jan 10, 2022
1 parent 8c0d07a commit 9879162
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cmd/configure.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,10 @@ var configureCmd = &cobra.Command{
string(password),
}

_ = os.MkdirAll(path.Dir(viper.ConfigFileUsed()), os.ModePerm)
err = os.MkdirAll(path.Dir(configPath), os.ModePerm)
if err != nil {
panic(err)
}
f, err := os.Create(configPath)
err = yaml.NewEncoder(f).Encode(&config)
if err != nil {
Expand Down

0 comments on commit 9879162

Please sign in to comment.