chore: tidy and code cleanup

This commit is contained in:
David Allen 2024-12-10 18:31:03 -07:00
parent d2b6178350
commit ad45a540f0
Signed by: towk
GPG key ID: 793B2924A49B3A3F
6 changed files with 7 additions and 14 deletions

View file

@ -1,8 +1,7 @@
package cmd
import (
"fmt"
"github.com/rs/zerolog/log"
"github.com/spf13/cobra"
"github.com/OpenCHAMI/configurator/pkg/config"
@ -20,7 +19,7 @@ var configCmd = &cobra.Command{
for _, path := range args {
// check and make sure something doesn't exist first
if exists, err := util.PathExists(path); exists || err != nil {
fmt.Printf("file or directory exists\n")
log.Error().Err(err).Msg("file or directory exists")
continue
}
config.SaveDefault(path)