Skip to content

Commit 9a2586c

Browse files
TheRootDaemonivanbalutadmmqzManagor
authored
gofumpt: add page (#20076)
Co-authored-by: Ivan Baluta <[email protected]> Co-authored-by: Dylan <[email protected]> Co-authored-by: Managor <[email protected]>
1 parent 1116fb6 commit 9a2586c

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

pages/common/gofumpt.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# gofumpt
2+
3+
> Strictly format Go files.
4+
> See also: `gofmt`.
5+
> More information: <https://github.com/mvdan/gofumpt#gofumpt>.
6+
7+
- Format Go files:
8+
9+
`gofumpt -w {{path/to/directory}}`
10+
11+
- [l]ist files whose formatting differs from `gofumpt`:
12+
13+
`gofumpt -l {{path/to/directory}}`
14+
15+
- Report all [e]rrors:
16+
17+
`gofumpt -e {{path/to/directory}}`
18+
19+
- Display [d]iffs:
20+
21+
`gofumpt -d {{path/to/directory}}`
22+
23+
- Format Go files with stricter rules:
24+
25+
`gofumpt -extra {{path/to/directory}}`
26+
27+
- Display [d]iffs with stricter rules:
28+
29+
`gofumpt -extra -d {{path/to/directory}}`
30+
31+
- Display help:
32+
33+
`gofumpt {{[-h|--help]}}`

0 commit comments

Comments
 (0)