X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=darcs-all;fp=darcs-all;h=4ad146a4680a378c5f9c7e9a4b14d7f3eaf85b8f;hp=ff7461677345eaee4d183b39bc3b46865f36079c;hb=8c90ee687f0751a86601415b54b61e120529b1ad;hpb=ab90e5fa171913fe777b2b6909030e3967e72bc6 diff --git a/darcs-all b/darcs-all index ff74616..4ad146a 100644 --- a/darcs-all +++ b/darcs-all @@ -268,6 +268,23 @@ sub darcsget { } } +sub darcsupstreampull { + my $localpath; + my $upstream; + my $line; + + for $line (@packages) { + $localpath = $$line{"localpath"}; + $upstream = $$line{"upstream"}; + + if ($upstream ne "-") { + if (-d $localpath) { + darcs ("pull", @_, "--repodir", $localpath, $upstream); + } + } + } +} + sub main { if (! -d "compiler") { die "error: darcs-all must be run from the top level of the ghc tree." @@ -324,6 +341,10 @@ sub main { if ($command eq "get") { darcsget @_; } + if ($command eq "upstreampull") { + shift; + darcsupstreampull @_; + } else { if ($command =~ /^(?:w|wh|wha|what|whats|whatsn|whatsne|whatsnew)$/) { # Hack around whatsnew failing if there are no changes