repository
0.0.0-20241118172039-580e9a47b1b5
Repository: https://github.com/melenium2/go-template.git
Documentation: pkg.go.dev
# README
Go template
A "business" go template that can be used to quickly initializing a new service. The example contains guidelines on how and where to write the code.
Initializing
Here we have used gonew
tool to initialize the template.
Installing gonew
More about gonew
here.
go install golang.org/x/tools/cmd/gonew@latest
Initializing the project
gonew github.com/Melenium2/go-template <new go.mod name>
For example
gonew github.com/Melenium2/go-template \
github.com/Melenium2/myservice
As a result the myservice
folder will be created in the current directory.
The project will be initialized with specified module name.
# bash
> ls
- ...
- myservice
- ...
// go.mod
module github.com/Melenium2/myservice
go 1.21