feat: add config:clear command

Closes #3537
This commit is contained in:
Jose Diaz-Gonzalez
2019-05-20 13:25:04 -07:00
parent a34d36c5d2
commit f977edabb2
7 changed files with 75 additions and 3 deletions

View File

@@ -0,0 +1,17 @@
package main
import (
"flag"
"os"
"github.com/dokku/dokku/plugins/config"
)
//clear all entries from the given environment
func main() {
args := flag.NewFlagSet("config:clear", flag.ExitOnError)
global := args.Bool("global", false, "--global: use the global environment")
noRestart := args.Bool("no-restart", false, "--no-restart: no restart")
args.Parse(os.Args[2:])
config.CommandClear(args.Args(), *global, *noRestart)
}