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

Re: [PATCH 1/2] git-config.txt: properly escape quotation marks in example

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 18, 2012, 23:39 UTC
Message-ID
<7vmx1rrcr4.fsf@alter.siamese.dyndns.org>
In-Reply-To
<7v7gswrkvm.fsf@alter.siamese.dyndns.org>
Junio C Hamano <gitster@pobox.com> writes:
Show 20 quoted lines
>> The bigger question is whether this example is improved by including
>> quotation marks, or whether they are just a distraction from the main
>> point.  I abstain.
>
> Thanks for spelling that bigger question out.  Given that the
> example is showing distinction between "X" vs "X for Y", I would say
> quotation is a distraction.
>
> If you spelled it as
>
> 	[core]
>         	gitproxy = sh -c 'proxy-command' for kernel.org
>
> does the do the right thing?  Or do we require the above to be
> spelled as
>
> 	[core]
>         	gitproxy = \"sh -c 'proxy-command'\" for kernel.org
>
> to work correctly?

I think the answer is "no", there is no way to specify anything other than a "path to the command" for gitproxy. So I think we should do this instead:

-- >8 --
Subject: [PATCH] git-config doc: unconfuse an example

One fictitious command "proxy-command" is enclosed inside a double quote pair, while another fictitious command "default-proxy" is not in the example, but the quoting does not change anything in the pair of examples. Remove the quotes to avoid unnecessary confusion.

Noticed by Michael Haggerty.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
 Documentation/git-config.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Documentation/git-config.txt b/Documentation/git-config.txt
index 5382753..b24faa8 100644
--- a/Documentation/git-config.txt
+++ b/Documentation/git-config.txt
@@ -251,7 +251,7 @@ Given a .git/config like this:
 
 	; Proxy settings
 	[core]
-		gitproxy="proxy-command" for kernel.org
+		gitproxy=proxy-command for kernel.org
 		gitproxy=default-proxy ; for all the rest
 
 you can set the filemode to true with
-- 
1.7.12.rc3.96.g0dba3eb
Previous: Junio C HamanoNext: Michael Haggerty
Message 4 of 7 in “Fix two minor problems in the docs for git-config”
  1. 0/2 Fix two minor problems in the docs for git-configmhagger@alum.mit.edu, Aug 18, 2012
  2. 1/2 git-config.txt: properly escape quotation marks in examplemhagger@alum.mit.edu, Aug 18, 2012
  3. Junio C HamanoAug 18, 2012
  4. Junio C HamanoAug 18, 2012
  5. Michael HaggertyAug 19, 2012
  6. 2/2 git-config.txt: fix examplemhagger@alum.mit.edu, Aug 18, 2012
  7. Junio C HamanoAug 18, 2012

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.