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

[PATCH 2/2] git-svn: don't die on rebuild when --upgrade is specified

From
EWEric Wong <normalperson@yhbt.net>
Date
Nov 5, 2006, 05:51 UTC
Message-ID
<11627058733587-git-send-email-normalperson@yhbt.net>
In-Reply-To
<11627058712379-git-send-email-normalperson@yhbt.net>

--copy-remote and --upgrade are rarely (never?) used together, so if --copy-remote is specified, that means the user really wanted to copy the remote ref, and we should fail if that fails.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
---
 git-svn.perl |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/git-svn.perl b/git-svn.perl
index cc3335a..4a56f18 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -3139,7 +3139,7 @@ sub copy_remote_ref {
 	my $ref = "refs/remotes/$GIT_SVN";
 	if (safe_qx('git-ls-remote', $origin, $ref)) {
 		sys(qw/git fetch/, $origin, "$ref:$ref");
-	} else {
+	} elsif ($_cp_remote && !$_upgrade) {
 		die "Unable to find remote reference: ",
 				"refs/remotes/$GIT_SVN on $origin\n";
 	}
-- 
1.4.3.3.ga126
Previous: Eric Wong
Message 2 of 2 in “git-svn: avoid printing filenames of files we're not tracking”
  1. 1/2 git-svn: avoid printing filenames of files we're not trackingEric Wong, Nov 5, 2006
  2. 2/2 git-svn: don't die on rebuild when --upgrade is specifiedEric Wong, Nov 5, 2006

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.