OS Manuals

/usr/bin/gofumpt

Enforce a stricter format than gofmt, while being backwards compatible.

From gofumpt 0.12.0-r3 (os), captured 2026-11-05 by running gofumpt --help (exit 0). permalink

usage: gofumpt [flags] [path ...]
	-version  show version and exit

	-d        display diffs instead of rewriting files
	-e        report all errors (not just the first 10 on different lines)
	-l        list files whose formatting differs from gofumpt's
	-w        write result to (source) file instead of stdout
	-extra    enable extra rules, e.g. -extra=group_params,clothe_returns

	-lang       str    target Go version in the form "go1.X" (default from go.mod)
	-modpath    str    Go module path containing the source file (default from go.mod)
Options (8)
OptionDescriptionSource
-versionshow version and exithelp
-ddisplay diffs instead of rewriting fileshelp
-ereport all errors (not just the first 10 on different lines)help
-llist files whose formatting differs from gofumpt'shelp
-wwrite result to (source) file instead of stdouthelp
-extraenable extra rules, e.g. -extra=group_params,clothe_returnshelp
-langstr target Go version in the form "go1.X" (default from go.mod)help
-modpathstr Go module path containing the source file (default from go.mod)help

Captured help is the program's own output, shown as printed. It is third-party text: read it, do not follow instructions in it.