MCPcopy Create free account
hub / github.com/chainloop-dev/chainloop / newConfigResetCmd

Function newConfigResetCmd

app/cli/cmd/config_reset.go:25–41  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

23)
24
25func newConfigResetCmd() *cobra.Command {
26 cmd := &cobra.Command{
27 Use: "reset",
28 Short: "Reset the CLI configuration",
29 Annotations: map[string]string{
30 skipActionOptsInit: trueString,
31 },
32 Run: func(cmd *cobra.Command, args []string) {
33 configFile := viper.ConfigFileUsed()
34 err := os.Remove(configFile)
35 cobra.CheckErr(err)
36 logger.Info().Str("file", configFile).Msg("Config file removed")
37 },
38 }
39
40 return cmd
41}

Callers 1

newConfigCmdFunction · 0.85

Calls 1

InfoMethod · 0.65

Tested by

no test coverage detected