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

Re: [PATCH] git-new-workdir: add windows compatibility

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
May 26, 2015, 12:35 UTC
Message-ID
<1fb8315dfaffb91ec4925bcc458e12a2@www.dscho.org>
In-Reply-To
<1432642835.17513.22.camel@mad-scientist.net>
Hi Paul,
On 2015-05-26 14:20, Paul Smith wrote:
Show 9 quoted lines
> On Tue, 2015-05-26 at 11:53 +0200, Johannes Schindelin wrote:
>> The biggest problem with `mklink` is that it is only supported on
>> Windows Vista and later, while I really like to keep Windows XP
>> support in Git for Windows.
> 
> No, the biggest problem with mklink is that you have to have
> administrative privileges to use it... from wikipedia:
> 
> http://en.wikipedia.org/wiki/NTFS_symbolic_link
It is even worse than that, as you pointed out below: administrators *can* permit non-administrators to create and use of symbolic links.
However, from a maintainer's perspective (which is my role in this thread), the compatibility problem is an even worse problem than the permissions.
Show 13 quoted lines
>> The default security settings in Windows Vista/Windows 7 disallow
>> non-elevated administrators and all non-administrators from creating
>> symbolic links. This behavior can be changed running "secpol.msc" the
>> Local Security Policy management console (under: Security Settings
>> \Local Policies\User Rights Assignment\Create symbolic links). It can
>> be worked around by starting cmd.exe with Run as administrator option
>> or the runas command.
> 
> Except even that is not so simple, as various StackOverflow questions
> and answers will show (I have to run so I can't look them up now).  I
> did try to get this to work a year or so ago, and although I'm in no way
> a Windows person (so maybe someone else would have better luck) I
> couldn't get it to work.
For what it is worth, I tried my hand a couple of years ago at the project to move git-new-workdir to use the `.git` *file* and alternates mechanisms, but that does not work because you really need a separate `.git/HEAD`.

Ciao, Johannes

Previous: Paul SmithNext: Michael J Gruber
Message 4 of 9 in “Re: [PATCH] git-new-workdir: add windows compatibility”
  1. Junio C HamanoMay 26, 2015
  2. Johannes SchindelinMay 26, 2015
  3. Paul SmithMay 26, 2015
  4. Johannes SchindelinMay 26, 2015
  5. Michael J GruberMay 29, 2015
  6. Duy NguyenMay 29, 2015
  7. Johannes SchindelinMay 29, 2015
  8. Karsten BleesMay 26, 2015
  9. Johannes SchindelinMay 27, 2015

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.