mirror of
https://github.com/project-zot/zot.git
synced 2026-06-17 04:48:26 +08:00
refactor(cli): added equivalent subcommands for each flag combination under every command (#1674)
- image command is now deprecated in favor of 'images' - cve command is now deprecated in favor of 'cves' Signed-off-by: Laurentiu Niculae <niculae.laurentiu1@gmail.com>
This commit is contained in:
@@ -40,7 +40,7 @@ func NewConfigCommand() *cobra.Command {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
configPath := path.Join(home + "/.zot")
|
||||
configPath := path.Join(home, "/.zot")
|
||||
switch len(args) {
|
||||
case noArgs:
|
||||
if isListing { // zot config -l
|
||||
@@ -115,7 +115,7 @@ func NewConfigAddCommand() *cobra.Command {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
configPath := path.Join(home + "/.zot")
|
||||
configPath := path.Join(home, "/.zot")
|
||||
// zot config add <config-name> <url>
|
||||
err = addConfig(configPath, args[0], args[1])
|
||||
if err != nil {
|
||||
@@ -145,7 +145,7 @@ func NewConfigRemoveCommand() *cobra.Command {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
configPath := path.Join(home + "/.zot")
|
||||
configPath := path.Join(home, "/.zot")
|
||||
// zot config add <config-name> <url>
|
||||
err = removeConfig(configPath, args[0])
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user