diff --git a/README.md b/README.md index 7fe6aeb..074a7a7 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,7 @@ +[![Go Reference](https://pkg.go.dev/badge/fortio.org/cli.svg)](https://pkg.go.dev/fortio.org/cli) +[![Go Report Card](https://goreportcard.com/badge/fortio.org/cli)](https://goreportcard.com/report/fortio.org/cli) +[![GitHub Release](https://img.shields.io/github/release/fortio/cli.svg?style=flat)](https://github.com/fortio/cli/releases/) + # cli Reduce boiler plate needed on each new Golang main functions (Command Line Interface) for both tools and servers (use [fortio.org/scli ServerMain()](https://github.com/fortio/scli#scli) for server) diff --git a/cli.go b/cli.go index 6b65e15..a4e5aa5 100644 --- a/cli.go +++ b/cli.go @@ -6,8 +6,8 @@ // Package cli contains utilities for command line tools and server main()s // to handle flags, arguments, version, logging ([fortio.org/log]), etc... // Configure using the package variables (at minimum [MinArgs] unless your -// binary only accepts flags), setup additional [flag]s before calling -// [Main] or [fortio.org/scli.ServerMain()] for configmap and dynamic flags +// binary only accepts flags), setup additional [flag] before calling +// [Main] or [fortio.org/scli.ServerMain] for configmap and dynamic flags // setup. package cli // import "fortio.org/cli" @@ -63,7 +63,7 @@ func usage(w io.Writer, msg string, args ...any) { // Main handles your commandline and flag parsing. Sets up flags first then call Main. // For a server with dynamic flags, call ServerMain instead. -// Will either have called ExitFunction() (defaults to [os.Exit]) +// Will either have called [ExitFunction] (defaults to [os.Exit]) // or returned if all validations passed. func Main() { quietFlag := flag.Bool("quiet", false, "Quiet mode, sets log level to warning")