[PATCH] archimport: Actually cope with merges from "remote" repositories. Plus: Nicer messages.
archimport was refusing to import commits that had merges from repositories that it didn't know about. Fixed. Also brings in nicer messages. Signed-off-by: Martin Langhoff <martin@catalyst.net.nz> Signed-off-by: Junio C Hamano <junkio@cox.net>
Martin Langhoff committed
Sep 30, 2005 at 19:15 UTC
37f15d50c93398eac90370cfe07315905501bdad
1 file changed
+7
-1
git-archimport.perl
+7
-1
@@ -228,10 +228,12 @@ foreach my $ps (@psets) {
228
# skip commits already in repo
229
#
230
if (ptag($ps->{id})) {
231
- $opt_v && print "Skipping already imported: $ps->{id}\n";
231
+ $opt_v && print " * Skipping already imported: $ps->{id}\n";
232
next;
233
}
234
235
+ print " * Starting to work on $ps->{id}\n";
236
+
237
#
238
# create the branch if needed
239
#
@@ -675,6 +677,10 @@ sub find_parents {
677
# that branch.
678
#
679
foreach my $branch (keys %branches) {
680
+
681
+ # check that we actually know about the branch
682
+ next unless -e "$git_dir/refs/heads/$branch";
683
+
684
my $mergebase = `git-merge-base $branch $ps->{branch}`;
685
die "Cannot find merge base for $branch and $ps->{branch}" if $?;
686
chomp $mergebase;