-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feature: support --link-mode=symlink
#5147
Comments
I don't mind supporting this, I was kinda waiting for it to be requested. |
Should be straightforward-ish if anyone wants to submit a PR -- it'd basically be copying the hardlink code, but changing the operation we use at the end. |
Hi @charliermarsh! Would it be a matter of swapping |
@danielenricocahall - Yeah that sounds roughly correct to me. |
We'll also need |
Closed by #5208. Thanks @danielenricocahall! |
I was about to ask for this for the same reasons and just found out it’s been released already! 🎉 |
I wonder if On macOS, you can also clone a directory, but I see that |
That’s a good idea. We should probably symlink at the directory level. |
Currently
--link-mode
supportscopy
,hardlink
, andclone
. I have myUV_CACHE_DIR
set to a mounted drive which prevents hardlinks and cloning ("invalid cross-device link"). Symlinks would work, however. This could really increase performance for my situation, rather than copying over a bunch of files. When I work in R, I userenv
which uses symlinks to a central cache successfully in the proposed way: https://github.com/rstudio/renv.More details about the specific use-case:
I work in ephemeral docker containers. My workflow is generally to start by running
uv pip sync requirements.txt
which currently is triggering a copy for each package. I mount a persistent drive to my container so that myuv
cache persists from session to session. Also worth noting that some collaborators mount the same drive and use the same cache, so that we benefit from each others' install time. Hopefully that isn't too risky, but it has worked well so far and works great in the aforementionedrenv
package in R.Related issue:
#2103
Thanks for making this amazing project!
The text was updated successfully, but these errors were encountered: