-
Notifications
You must be signed in to change notification settings - Fork 155
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
Download only subdirectory for GitHub packages when appropriate #2012
Comments
It should be possible, but I'm not sure if there's anything made available by the GitHub API. We could implement support for this when installing packages via git remotes though, e.g.
For reference, here's the git command we generate to check out sources from a particular repository. Lines 499 to 504 in 1c8c64c
All that said -- it's also possible that R packages within a project sub-directory might still depend on files outside of that sub-directory, so I'm not sure if this is something we could do by default. |
Yes, after some investigation on other fronts, I am not sure it is a great idea, or even a particularly useful one. When I was trying to figure out how this might actually work, I found that the |
Thanks! In that case, I think this issue can be closed? Let me know if there's yet anything else I can improve on the |
When installing a package from GitHub where the package is in a subdirectory of the main repository,
renv::install()
downloads the entire repository. For some repositories this may be a non-issue, but if the repository is large (and the R package is only a small part of the repository), this may result in a long, slow download.Might it be possible to implement a
sparse-checkout
or equivalent to reduce downloads and improve install times in this situation?The text was updated successfully, but these errors were encountered: