git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] archimport: Actually cope with merges from "remote" repositories. Plus: Nicer messages.

From
MLMartin Langhoff <martin@catalyst.net.nz>
Date
Sep 30, 2005, 07:15 UTC
Message-ID
<11280645122296-git-send-email-martin@catalyst.net.nz>

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>
---
 git-archimport.perl |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
d118e96e7f08fcd0963eac8d9e6f18e13f553a41
diff --git a/git-archimport.perl b/git-archimport.perl
--- a/git-archimport.perl
+++ b/git-archimport.perl
@@ -228,10 +228,12 @@ foreach my $ps (@psets) {
     # skip commits already in repo
     #
     if (ptag($ps->{id})) {
-      $opt_v && print "Skipping already imported: $ps->{id}\n";
+      $opt_v && print " * Skipping already imported: $ps->{id}\n";
       next;
     }
 
+    print " * Starting to work on $ps->{id}\n";
+
     # 
     # create the branch if needed
     #
@@ -675,6 +677,10 @@ sub find_parents {
     # that branch.
     #
     foreach my $branch (keys %branches) {
+
+	# check that we actually know about the branch
+	next unless -e "$git_dir/refs/heads/$branch";
+
 	my $mergebase = `git-merge-base $branch $ps->{branch}`;
 	die "Cannot find merge base for $branch and $ps->{branch}" if $?;
 	chomp $mergebase;
Message 1 of 1 in “archimport: Actually cope with merges from "remote" repositories. Plus: Nicer messages.”
  1. archimport: Actually cope with merges from "remote" repositories. Plus: Nicer messages.Martin Langhoff, Sep 30, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.