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

Re: Update symlinks after changing core.symlinks

From
AZAndrej Zhilenkov <azhilenkov@gmail.com>
Date
Apr 4, 2025, 05:51 UTC
Message-ID
<CAArAzAr+YPwVXJo8mjkyQG8uWv=wt89tYyp6TL-rNzvwVYm9YA@mail.gmail.com>
In-Reply-To
<Z-8K9ZIt4j_UMNZm@tapette.crustytoothpaste.net>
> On 2025-04-02 at 22:41:50, brian m. carlson wrote:
> > What is your particular use case that requires changing this value?
Hi, thank you for your reply.

Just recently started working with symlinks in git and I've found that in Git for Windows they are disabled by default (https://gitforwindows.org/symbolic-links.html). It's possible to just change the setting in system config or override it in global config, but it's probably safe to assume that the average Windows user will have them disabled. And if your repo needs them, it's probably more reasonable to ask the user to enable symlinks in a local config, not global. So, you can enable them during clone `git clone -c core.symlinks=true` but I guess as a user (and symlinks not being used very often) you typically learn about repo having symlinks and you needing them after repo was cloned. So this is the use case I've found for `git checkout` or some other command refreshing files based on current `core.symlinks` value. Without this feature you would need to have a script where you list all symlinks, remove them with `rm` / `del` and only then you can check them out.

Maybe there are similar cases but on Unix when users would want `core.symlinks` disabled globally and be enabled on a per-repo basis but I can't imagine why.

Previous: brian m. carlsonNext: brian m. carlson
Message 4 of 6 in “Update symlinks after changing core.symlinks”
  1. Andrej ZhilenkovApr 2, 2025
  2. brian m. carlsonApr 2, 2025
  3. brian m. carlsonApr 3, 2025
  4. Andrej ZhilenkovApr 4, 2025
  5. brian m. carlsonApr 4, 2025
  6. Andrej ZhilenkovApr 10, 2025

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.