The main dnsimple
package is defined in the /dnsimple
subfolder of the dnsimple/dnsimple-go
repository. Therefore, please note that you will need to move into the subfolder to run any go
command that assumes the current directory to be the package root.
For example, to get the dependencies you will have to run:
git clone [email protected]:dnsimple/dnsimple-go.git
cd dnsimple
go get ./...
Likewise, when you include this library as dependency, you will need to use
import "github.com/dnsimple/dnsimple-go/dnsimple"
and not
import "github.com/dnsimple/dnsimple-go"
Clone the repository in your workspace and move into it:
git clone [email protected]:dnsimple/dnsimple-go.git
cd dnsimple-go
Run the test suite to check everything works as expected.
The following instructions uses $VERSION
as a placeholder, where $VERSION
is a MAJOR.MINOR.BUGFIX
release such as 1.2.0
.
-
Run the test suite and ensure all the tests pass.
-
Set the version in
dnsimple.go
:Version = "$VERSION"
-
Run the test suite and ensure all the tests pass.
-
Finalize the
## main
section inCHANGELOG.md
assigning the version. -
Commit and push the changes
git commit -a -m "Release $VERSION" git push origin main
-
Wait for CI to complete.
-
Create a signed tag.
git tag -a v$VERSION -s -m "Release $VERSION" git push origin --tags
Submit unit tests for your changes. You can test your changes on your machine by running the test suite (see below).
When you submit a PR, tests will also be run on the continuous integration environment via GitHub Actions.
To run the test suite:
go test ./... -v
To run the test suite in a live environment (integration):
export DNSIMPLE_TOKEN="some-token"
go test ./... -v