A CLI tool to make git changes across many repos, especially useful with Microservices.
A CLI tool to make git changes across many repos, especially useful with Microservices. You can learn more about microplane in this introductory blogpost.
"the lemon is Git{Hub,Lab}"
You can download a pre-built version of Microplane from the Github releases.
Alternately, you can download via
go get github.com/clever/microplane/cmd. In this case the binary will be installed to
$GOPATH/bin/microplane
The
GITHUB_API_TOKENenvironment variable must be set for Github. This should be a GitHub Token with
reposcope.
The
GITLAB_API_TOKENenvironment variable must be set for Gitlab. This should be a GitLab access token
Optionally: The
GITLAB_URLenvironment variable can be set to use a Gitlab on-premise setup, otherwise it will use https://gitlab.com.
Microplane has an opinionated workflow for how you should manage git changes across many repos. To make a change, use the following series of commands.
For an in-depth example, check out the introductory blogpost.
Microplane is a Golang project. It uses
depfor vendoring.
First, clone the repo into your
GOPATH. Next, run
make install_deps(this calls
dep). To build, run
make build. You should now have a working build of Microplane in
./bin/mp.
Microplane parallelizes various git commands and API calls.
At each step in the Microplane workflow, a repo only moves forward if the previous step for that repo was successful.
We persist the progress of a Microplane run in the following local file structure.
mp/ init.json repo1/ clone/ clone.json plan/ plan.json push/ push.json merge/ merge.json repo2/ ...
To publish a release:
VERSIONwith the new version and
CHANGELOG.mdwith a description of the changes.