Prerequisites

Last updatedJuly 21, 2021

This page details prerequisites for using the Nextmv API.

Install Go

We recommend asdf for installing and managing Go versions. Nextmv requires at least Go 1.13.

Set environment variables

Ensure that the following environment variables are set in your ~/.bashrc, ~/.zshrc or a similar configuration file.

export GOPATH=$(go env GOPATH)
export GOROOT=$(go env GOROOT)
export GOPRIVATE=github.com/nextmv-io/*
export PATH=$PATH:$GOPATH/bin

Note that if you installed Go directly from Golang, you do not need to add exports for GOPATH or GOROOT. If you installed go via Homebrew, you will need to add those lines to ~/.zshrc. If you were using bash previously, also be sure to source ~/.zshrc by running source ~/.zshrc.

Set git to clone repositories over SSH

Your ~/.gitconfig will work best if it directs git to clone repositories over ssh. Add the following to your configuration file.

[url "git@github.com:"]
    insteadOf = https://github.com/
Was this helpful?