Makefile consists of all the important commands required by developers and DevOps team for any Golang project:
make in the terminal to go through all the available commands:
The commands include:
buildcommands to build binaries for the current system and various other platform architectures and OS.
setupcommands to set up dev dependencies and packages required for linting, documentation, etc.
docscommands to generate documentation on swagger and start local swagger UI.
formattingcommands to format go files.
test and coveragecommands to output status of unit tests, benchmarks, and code coverage in different available formats like JSON, HTML, etc.
static checkcommands to find security and linting issues in code in different available formats like JSON, HTML, etc.
runcommands to run the application for different environments, dev, staging and prod, etc.
cleancommands to run cleanup on go application and by removing generated binaries and reports.
dockercommands to build, run, remove... Docker image and container.
helpcommand to open up the above terminal output.