Skip to content

arbourd/git-get

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

64 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

git-get

git get clones repositories to your GETPATH in the same fashion as go get.

Usage

Get a repository to the default GETPATH ~/src

$ git get github.com/arbourd/git-get
~/src/github.com/arbourd/git-get

$ git get https://github.com/arbourd/git-get.git
~/src/github.com/arbourd/git-get

$ git get [email protected]:arbourd/git-get.git
~/src/github.com/arbourd/git-get

Set a custom GETPATH with git config.

$ git config --global get.path "~/dev"

$ git get github.com/arbourd/git-get
~/dev/github.com/arbourd/git-get

Set a custom GETPATH with the environmental variable $GETPATH.

$ export GETPATH=~/dev

$ git get github.com/arbourd/git-get
~/dev/github.com/arbourd/git-get

Using SSH as the default

By default, when getting a repository without specifying a protocol (eg: github.com/arbourd/git-get) HTTPS will be used.

If you would prefer to use SSH or any other protocol, configure your Git config to redirect.

$ git config --global url.ssh://[email protected]/.insteadOf https://github.com/

Installation

Install with brew.

$ brew install arbourd/tap/git-get

Install with go install.

$ go install github.com/arbourd/git-get@latest