Fetch and save .gitignore file from github/gitignore quickly.
$ get-git-ignore --lang=Go
$ ls -a
.gitignore
--lang
: Language for .gitignore.--out
: Path to save .gitignore file. Default is.gitignore
.
$ go get github.com/handlename/go-get-git-ignore/cmd/get-git-ignore
Using with peco,
you can filter candidates interactively.
Install peco and put like below to your .zshrc
file.
function _peco_ggi_list () {
lang=$(get-git-ignore | peco)
if [ -n "$lang" ]; then
get-git-ignore --lang=$lang
fi
}
alias ggi=_peco_ggi_list