rtomayko (owner)

Revisions

gist: 206287 Download_button fork
public
Description:
git-grab
Public Clone URL: git://gist.github.com/206287.git
Embed All Files: show embed
Bash #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh
 
[ $# -eq 0 ] && {
    echo "usage: git-grab username [repo]"
    exit 1
}
 
username="$1"
 
if [ -n "$2" ] ; then
repo="$2"
else
repo=$(basename $(pwd))
fi
 
git remote add $username git://github.com/$username/$repo.git
git fetch $username