You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
276 B

2 years ago
package cmd
2 years ago
import (
"flag"
"fmt"
"os"
"strconv"
)
2 years ago
2 years ago
func Root() error {
args := flag.NewFlagSet("root", flag.ExitOnError)
verbose := args.Bool("verbose", false, "Extra logging")
args.Parse(os.Args[1:])
fmt.Printf("Hi %s", strconv.FormatBool(*verbose))
2 years ago
return nil
}