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

Re: git-pull-script hates me

From
Greg KH <greg@kroah.com>
Date
Jul 6, 2005, 20:46 UTC
Message-ID
<20050706204627.GA19481@kroah.com>
In-Reply-To
<Pine.LNX.4.58.0507061335100.4159@g5.osdl.org>
On Wed, Jul 06, 2005 at 01:37:55PM -0700, Linus Torvalds wrote:
Show 22 quoted lines
> 
> 
> On Wed, 6 Jul 2005, Greg KH wrote:
> >
> > I just updated to the latest git tree, and now get the following when I
> > try to pull from a ssh repo:
> > 
> >  $ git-pull-script gregkh@someserver.org:/public_html/udev.git/
> >  fatal: I don't like '@'. Sue me.
> > 
> > So I drop the @ and then get:
> >  $ git-pull-script someserver.org:/public_html/udev.git/
> >  fatal: I don't like '_'. Sue me.
> 
> Heh. It really is personal.
> 
> The new git-pack handling tries to avoid special characters, because it 
> passes some things off to a shell (ie it opens up an ssh connection.
> 
> But yeah, it's being a bit too anal. Just look at connect.c: shell_safe(),
> and add both '_' and '@' to the safe list (and any other safe characters),
> and off you go.
Ok, below is a patch for this.  It works, but then errors out with:
	bash: git-upload-pack: command not found
	fatal: unexpected EOF

So I'm guessing that I have to convince the server owner to update their version of git too?

thanks,
greg k-h
--------------------
Subject: allow _ and @ in addresses
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
diff --git a/connect.c b/connect.c
--- a/connect.c
+++ b/connect.c
@@ -57,6 +57,7 @@ static char *shell_safe(char *url)
 		['A'...'Z'] = 1,
 		['.'] = 1, ['/'] = 1,
 		['-'] = 1, ['+'] = 1,
+		['@'] = 1, ['_'] = 1,
 		[':'] = 1
 	};
 
Previous: Linus TorvaldsNext: Greg KH
Message 3 of 10 in “git-pull-script hates me”
  1. Greg KHJul 6, 2005
  2. Linus TorvaldsJul 6, 2005
  3. Greg KHJul 6, 2005
  4. Greg KHJul 6, 2005
  5. Linus TorvaldsJul 6, 2005
  6. Junio C HamanoJul 6, 2005
  7. Linus TorvaldsJul 6, 2005
  8. Make sq_expand() available as sq_quote().Junio C Hamano, Jul 8, 2005
  9. Make sq_expand() available as sq_quote().Junio C Hamano, Jul 8, 2005
  10. Use sq_quote() to properly quote the parameter to call shell.Junio C Hamano, Jul 8, 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.