Long story short:
library(miniCRAN)
repo <- “https://cran.rstudio.com”
pkgs <- available.packages()[,1]
pkgList <- pkgDep(pkgs, repos=repo, type=”source”, suggests=FALSE)in R:
makeRepo(pkgList, path=”D:/Rpackages”, repos=repo, type=c(“win.binary”))
will download every existing packages, as windows binary, to the folder “rpackages” on D:\ drive