go-many-git

command module
v0.0.0-...-0b373f6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 1, 2017 License: GPL-3.0 Imports: 10 Imported by: 0

README

go-many-git

Tool to manage multiple git repositories

Requirements

  • Proper go installation with GOPATH set
  • git >= 1.8.5

Installation

go get -u github.com/abrochard/go-many-git
go install github.com/abrochard/go-many-git
echo 'alias gmg=$GOPATH/bin/go-many-git' >> ~/.bashrc

Usage

Usage: gmg [@tag] <comand> [<args>]

Go-many-git basic usage is to run a particular git command across multiple repos
For example, 'gmg pull' runs 'git pull' across all registered repos
By default 'gmg' alone runs 'git status'

Optionally, a repos can be identified by a shared tag (@example), making it possible to target a subset of repos
ie: `gmg @api pull` runs `git pull` on all repos tagged with `api`

Go-many-git accepts all git commands, but here are a few gmg specific commands:

   [@tag] register <path>    Add the repo in <path> to the list of repos, with an optional tag
   unregister <path>         Remove the repo in <path> from the list
   [@tag] b                  Shorthand to display the repos current branch
   list                      Print all registered repos
   help                      Print this help

Note that gmg writes its repo list to a config file located under ~/.config/gmg-repos.json

Acknowledgements

gmg is very inspired by the amazing mr and gr tools. A big thanks to them.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL