From 1ec52e076d8ea7f714fc2800f9c253c6f56dce41 Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Tue, 22 Mar 2011 19:23:09 -0500 Subject: git hub add --- bin/git/git-hub | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'bin/git') diff --git a/bin/git/git-hub b/bin/git/git-hub index e2bee74..6f2fe7d 100755 --- a/bin/git/git-hub +++ b/bin/git/git-hub @@ -131,8 +131,7 @@ sub run_command_clone { $self->run_command_clone($repo); { my $d = pushd($repo); - git "remote add $owner git://github.com/$owner/$repo.git"; - git "remote update"; + $self->run_command_add($owner, $repo); } } else { @@ -175,6 +174,16 @@ sub run_command_pullreq { ); } +sub run_command_add { + my $self = shift; + my ($owner, $repo) = @_; + die "usage: git hub add " + unless @_ == 2; + + git "remote add $owner git://github.com/$owner/$repo.git"; + git "fetch $owner"; +} + sub _github { my $self = shift; my %opts = @_; -- cgit v1.2.3-54-g00ecf