I suppose currently each of your R package live in its own library ?
If pkgVersion1
is installed in library/v1
and pkgVersion2
is installed in library/V2
, you could point to the correct library in your different project: library(pkgVersion1, lib.loc = "library/v1")
However, if you want your project to be standalone working project with their own set of dependencies, I suggest to look at packrat
that will help you create and manage a library inside each project so that you have no system dependencies issues.
I wrote shortly about packrat is this topic