]> Tony Duckles's Git Repositories (git.nynim.org) - dotfiles.git/blob - bin/github-grab
Initial commit
[dotfiles.git] / bin / github-grab
1 #!/bin/sh
2
3 [ $# -eq 0 ] && {
4 echo "usage: github-grab username [repo]"
5 exit 1
6 }
7
8 username="$1"
9
10 if [ -n "$2" ] ; then
11 repo="$2"
12 else
13 repo=$(basename $(pwd))
14 fi
15
16 command="git remote add $username git://github.com/$username/$repo.git"
17 echo $command
18 $command
19
20 command="git fetch $username"
21 echo $command
22 $command