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

Re: [PATCH 3/3] difftool: Disable --symlinks on cygwin

From
Junio C Hamano <gitster@pobox.com>
Date
Jul 26, 2012, 19:04 UTC
Message-ID
<7vhasu739n.fsf@alter.siamese.dyndns.org>
In-Reply-To
<CAJDDKr4z_ddwe7s8dY80dZJMNP=75VK6NjOV0WCqFL_LDuMpBA@mail.gmail.com>
David Aguilar <davvid@gmail.com> writes:
Show 40 quoted lines
> On Thu, Jul 26, 2012 at 4:31 AM, Erik Faye-Lund <kusmabite@gmail.com> wrote:
>> On Wed, Jul 25, 2012 at 5:14 AM, David Aguilar <davvid@gmail.com> wrote:
>>> Symlinks are not ubiquitous on Windows so make --no-symlinks the default.
>>>
>>> Signed-off-by: David Aguilar <davvid@gmail.com>
>>> ---
>>> I don't have cygwin so I can't verify this one myself.
>>> Is 'cygwin' really the value of $^O there?
>>>
>>>  git-difftool.perl | 3 ++-
>>>  1 file changed, 2 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/git-difftool.perl b/git-difftool.perl
>>> index 591ee75..10d3d97 100755
>>> --- a/git-difftool.perl
>>> +++ b/git-difftool.perl
>>> @@ -291,7 +291,8 @@ sub main
>>>                 gui => undef,
>>>                 help => undef,
>>>                 prompt => undef,
>>> -               symlinks => $^O ne 'MSWin32' && $^O ne 'msys',
>>> +               symlinks => $^O ne 'cygwin' &&
>>> +                               $^O ne 'MSWin32' && $^O ne 'msys',
>>
>> I thought Cygwin supported (their own version of) symlinks? What's the
>> rationale for not using it by default there?
>
> I am not a Cygwin user so I cannot verify whether it is a good or bad idea.
>
> I have a few questions regarding symlinks on Cygwin:
>
> Do the symlinks work consistently with the Perl symlink() function?
> Can we always rely on this capability being available?
> Do all win32 filesystems support it?
> Do all builds of cygwin perl support it?
>
> If any of these answers are "no" or "maybe", then an improvement
> beyond this patch would be to perhaps support a `difftool.symlinks`
> configuration variable so that the user can tell us what to use as the
> default.

I would think it is an independent topic that can be used by people not on Windows. It is good to be conservative by disabling symlinks by default.

Thanks.
Previous: David AguilarNext: Junio C Hamano
Message 8 of 9 in “Incremental updates for da/difftool-updates”
  1. 0/3 Incremental updates for da/difftool-updatesDavid Aguilar, Jul 25, 2012
  2. 1/3 difftool: Handle finding mergetools/ in a path with spacesDavid Aguilar, Jul 25, 2012
  3. 2/3 difftool: Check all return codes from compare()David Aguilar, Jul 25, 2012
  4. 3/3 difftool: Disable --symlinks on cygwinDavid Aguilar, Jul 25, 2012
  5. Stefano LattariniJul 25, 2012
  6. Erik Faye-LundJul 26, 2012
  7. David AguilarJul 26, 2012
  8. Junio C HamanoJul 26, 2012
  9. Junio C HamanoJul 25, 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.