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

Re: How can a custom merge tool get access to file shell variables?

From
KAKeith Amidon <keith@nicira.com>
Date
Aug 21, 2008, 23:31 UTC
Message-ID
<1219361486.16860.50.camel@kea-nicira-lt.nicira.com>
In-Reply-To
<20080821221524.GA25429@hashpling.org>
Hi Charles,

Thanks for your reply to my issue. To answer your question, I did read the git mergetool man page too. For some reason I felt that the information in the git config page was more complete/specific for this case. Anyway, now I understand how it works (and quoting issues I haven't had to worry about because I don't have weird filenames aside), the setup actually works very nicely. If you would be interested and could provide some guidance on roughly what you would like to see I'd be happy to take a crack at an initial modification to the git mergetool man page to include an example similar to mine below with proper quoting so paths with spaces in them work, etc.

Thanks again for your response and for the excellent work you and everyone involved in git development have been doing.

             --- Keith

P.S. -- Sorry if you get two copies Charles. My previous version of this message was rejected by the mailing list because I forgot to send w/o HTML.

On Thu, 2008-08-21 at 23:15 +0100, Charles Bailey wrote:
Show 20 quoted lines
> Did you also try the git mergetool man page (not that it's much
> better!)?
> 
> The point of the custom mergetool patch was to make using a new,
> previously unknown merge tool a 'simple' configuration exercise rather
> than a patch or scripting exercise. At the time, an 'eval' approach
> was the compromise between ease of implementation and preventing
> environmental pollution.
> 
> It's not the most beautiful of solutions, especially since escaping
> quotes and spaces in either .gitconfig or in a git config command line
> of something that is later going to be expanded by the shell is
> something of a mind bender.
> 
> An example in the documentation would be a really good idea - you are
> not the first person to have asked about how to use the custom merge
> tool feature. I'm feeling a little guilty about not adding my name to
> the man page when I submitted the patch. It's not Ted's fault that the
> custom merge tool section is badly explained; it's mine.
> 
Previous: Charles Bailey
Message 4 of 4 in “How can a custom merge tool get access to file shell variables?”
  1. Keith AmidonAug 19, 2008
  2. Keith AmidonAug 19, 2008
  3. Charles BaileyAug 21, 2008
  4. Keith AmidonAug 21, 2008

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.