Skip to content
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

copy/updating packages when the library is in the user directory #97

Open
talgalili opened this issue Jul 29, 2017 · 4 comments
Open

copy/updating packages when the library is in the user directory #97

talgalili opened this issue Jul 29, 2017 · 4 comments

Comments

@talgalili
Copy link
Owner

With respect to the global library, I am using two work machines and both use a folder for my user profile for the R library automatically. It is in my documents \R\win-library\3.2\ (currently)
I think the updateR() will have a problem if the old and new folder are the same. Not sure how you’ll check and avoid that even if the user does decide to migrate the library. I agree that the migration is necessary if the default location for the library is used (under program files…)

@m-stanley
Copy link

I'm not sure what the issue is here, but a problem I encounter with R is that my library is in My Documents at C:\Users\m-stanley\Documents\R\win-library\3.4\ or whatever the version number is, and it's never copied over to the new version with installr. That's super annoying - so if that's this issue, I definitely encounter it!

@talgalili
Copy link
Owner Author

@m-stanley this is indeed the issue. I'll need to improve the logic of the library detection to solve it, but I don't see how I'll get the time to do it in the near future...

@russHyde
Copy link
Contributor

russHyde commented Oct 9, 2019

hi @talgalili , I think I've just hit this problem on my windows laptop too.

Updating from R3.5.1 to R3.6.1

# In R3.5.1
.libPaths()
# [1] C:/Users/russ_/OneDrive/Documents/R/win-library/3.5
# [2] C:/Program Files/R/R-3.5.1/library

All of my non-core R packages are installed in the first of these two libraries (because the Program Files dir is non-writable)

After running installr::updateR() (v 0.22.0) my .libPaths in R3.6.1 is as follows:

# In R 3.6.1
.libPaths()
# [1] C:/Program Files/R/R-3.6.1/library

IfI then use install.packages(some_package) in the fresh R 3.6.1; windows prompts me to start a new personal library. By default this has the same structure as the R3.5 personal library: C:/Users/russ_/OneDrive/Documents/R/win-library/3.6

So I thought I'd be able to copy packages from the .../win-library/3.5 to .../win-library/3.6 using installr::copy.packages.between.libraries but that failed for these two libraries because they didn't have a ./library subdirectory that contained the package definitions.

I rarely use windows for R work, but was wondering whether there might be a way to ensure that packages are transferred from non-standard libraries correctly during installr::updateR()

Happy to help if I can

@talgalili
Copy link
Owner Author

talgalili commented Oct 10, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants