This content originally appeared on DEV Community 👩💻👨💻 and was authored by Maxime Guilbert
While linting your project, you can have the following error :
pkg/apis/dogs.go:11: File is not `gofmt`-ed with `-s` (gofmt)
To resolve the issue, execute the following command :
gofmt -s -w .
It will simplify the code (with the option -s
) and write the result back (with the option -w
) on all the current folder (with .
).
I hope it will help you! 🍺
This content originally appeared on DEV Community 👩💻👨💻 and was authored by Maxime Guilbert

Maxime Guilbert | Sciencx (2022-11-28T14:59:00+00:00) How to debug : File is not `gofmt`-ed with `-s` (gofmt). Retrieved from https://www.scien.cx/2022/11/28/how-to-debug-file-is-not-gofmt-ed-with-s-gofmt/
Please log in to upload a file.
There are no updates yet.
Click the Upload button above to add an update.