Closed dgkf closed 2 months ago
Might be worth to link to the thread in r-package-devel with some (background) information/comments about this.
Thanks, just submitted a PR for this: https://github.com/r-multiverse/r-multiverse.github.io/pull/14. This is all great to know, and in the R-multiverse docs, I would prefer to avoid making specific claims about the nuances of install.packages()
or available.packages()
.
I only discovered this after being baffled by package installs at one point, but the order of repositories listed in
options("repos")
does not indicate precedence as suggested here.Given the packages in all
"repos"
,available.packages
will return the latest version of each package by default (regardless of which repo it comes from). The order of"repos"
only factors in if there are version ties.From
?available.packages
, emphasis mine:and
You can alter this behavior using
options("available_packages_filters")