Skip to content
Prev 1408 / 3656 Next

How to get write permissions for (lib="~/.R/library") ??

On Sat, Oct 30, 2010 at 1:34 AM, pragya agarwal <pragya015 at gmail.com> wrote:
I believe this means something went wrong, and in the past you may
have run something as root or another user.  Or that you have the
library in .R, but the default in Ubuntu deb packaging is not a dot
file, it is R/x86_64-pc-linux-gnu-library.  That's a setting in
/etc/R/Renviron. I have:

R_LIBS_USER=${R_LIBS_USER-'~/R/x86_64-pc-linux-gnu-library/2.12'}
R_LIBS_SITE=${R_LIBS_SITE-'/usr/local/lib/R/site-library:/usr/lib/R/site-library:/usr/lib/R/library'}

Assuming that .R/library is what you really want to use, just give
yourself permission there.

Below, suppose "username" is you user login name, the one you want to
own the files.

You can re-set the permissions.  This isn't an R thing, it is just a
linux thing.  Open a terminal

# cd
# ls -la .R

That should let you see.

# cd .R
# chown -R username library

"username" will now own library and everything below in it.

PJ