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

[RFC/PATCH 1/2] git-push reports the URL after failing.

From
Junio C Hamano <junkio@cox.net>
Date
Apr 7, 2007, 06:04 UTC
Message-ID
<7vfy7cg1o8.fsf@assigned-by-dhcp.cox.net>

This came up on #git when somebody was getting 'unable to create ./objects/tmp_oXXXX' but sweared he had write permission to that directory. It turned out that the repository URL was changed and he was accessing a repository he does not have a write permission anymore.

I am not sure how much this would have helped somebody who believed he was accessing location when the permission of that location was changed while he was looking the other way, though. But giving more information on the error path would be better, and the next change would be helped with this as well.

Signed-off-by: Junio C Hamano <junkio@cox.net>
---
 builtin-push.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/builtin-push.c b/builtin-push.c
index 70b1168..23143be 100644
--- a/builtin-push.c
+++ b/builtin-push.c
@@ -339,6 +339,8 @@ static int do_push(const char *repo)
 		err = run_command_v_opt(argv, RUN_GIT_CMD);
 		if (!err)
 			continue;
+
+		error("failed to push to '%s'", uri[i]);
 		switch (err) {
 		case -ERR_RUN_COMMAND_FORK:
 			die("unable to fork for %s", sender);
Message 1 of 1 in “git-push reports the URL after failing.”
  1. 1/2 git-push reports the URL after failing.Junio C Hamano, Apr 7, 2007

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.