r-universe-org / hitchhikers-guide

R-universe docs
http://docs.r-universe.dev/
1 stars 0 forks source link

Faq about old/forked packages #12

Closed jeroen closed 1 month ago

jeroen commented 3 months ago

Q: Can we use r-universe to host older versions of CRAN packages?

A: this is possible, but be careful that it may not work as you expect. R's install.packages() and update.packages() will always install the latest version of a package it can find in any of the available repos. So the package may automatically get updated to the CRAN version on the end-user machine.

Q: can we use r-universe to host a fork of a CRAN package?

A: this is possible but generally a bad idea. Your package may automatically get overwritten by the CRAN version of the package the next time the user runs install.packages() or update.packages(). Also note that other packages may depend on this package, and might not be compatible with your fork.