Documentation ¶
Overview ¶
Package tooling provides common tooling install setup for go linting, formatting, and other Go tools with nice console output for interactive use.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InstallTools ¶
InstallTools installs tooling for the project in a local directory to avoid polluting global modules.
func SilentInstallTools ¶
SilentInstallTools reads the stdout and then uses a spinner to show progress. This is designed to swallow up a lot of the noise with go install commands. Originally found from: https://www.yellowduck.be/posts/reading-command-output-line-by-line/ and modified.
func SpinnerStdOut ¶
SilentInstallTools reads the stdout and then uses a spinner to show progress. binary: name of tool to run, such as go, gofumpt, etc.
cmdargs: slice of string arguments to pass into command
list: optional list of strings that the command will iterate against.
- If no arguments, will range 1x over blank string
- If list is provided then loop will provide each invocation against it.
Example: SpinnerStdOut("go",[]string{"mod","tidy"},[]string{""})
Example: SpinnerStdOut("go",[]string{"install"},[]string{ "golang.org/x/tools/cmd/goimports@master","github.com/sqs/goreturns@master"}) This is designed to swallow up a lot of the noise with go install commands. Originally found from: https://www.yellowduck.be/posts/reading-command-output-line-by-line/ and modified.
Types ¶
This section is empty.