Only attempt to parse config file if it is specified by flag (#169)
Previously, the behavior was to search for the config file in a variety of locations. Now we only attempt to load a config file if it has been explicitly specified with `-c` or `--config`. Fixes #165.
This commit is contained in:
committed by
GitHub
parent
df19fd4b7c
commit
0702dccb7f
+1
-1
@@ -46,7 +46,7 @@ wish to override the default value.
|
||||
`,
|
||||
}
|
||||
|
||||
rootCmd.PersistentFlags().String("config", "", "Path to a configuration file")
|
||||
rootCmd.PersistentFlags().StringP("config", "c", "", "Path to a configuration file")
|
||||
|
||||
return rootCmd
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user