Forrest logo
back to context overview

go-fmt

List of commands for go-fmt:

  • go-fmt:tldr:67f62 go-fmt: Print which format commands are run as they are run.
    $ go fmt -x
    try on your machine
    explain this command
  • go-fmt:tldr:75e66 go-fmt: Format a specific Go package in your import path (`$GOPATH/src`).
    $ go fmt ${path-to-package}
    try on your machine
    explain this command
  • go-fmt:tldr:81b42 go-fmt: Print what format commands would've been run, without modifying anything.
    $ go fmt -n
    try on your machine
    explain this command
  • go-fmt:tldr:9c885 go-fmt: Format Go source files in the current directory.
    $ go fmt
    try on your machine
    explain this command
back to context overview