goyaccfmt
auto reformats goyacc
source code by calling gofmt
.
The following command reformats a source file goyaccfmt a.y For inline reformat, please use option goyaccfmt -w a.y To the right is the difference before and after auto reformatting the grammar rule file of SQLFlow. |
-
To beautify one or more files and write to stdout:
goyaccfmt a.yaml b.yaml c.yaml
-
To beautify one or more files in the replace mode:
goyaccfmt -w a.yaml b.yaml c.yaml
-
To beautify stdin and write to stdout:
cat a.yaml | goyaccfmt
-
To beautify stdin and write to a file:
cat a.yaml | goyaccfmt > b.yaml