new functions for managing existing miniCRAN repo

Major additions:
* add new packages to existing miniCRAN repo
* check for package updates from CRAN-like repo
* add updated packages from CRAN-like repo
* update `twodigitRversion` to handle more types

NOTE: there appears to be a small amount of overlap between the new `add.packages.miniCRAN()` and the existing `addPackage`:
- The new one does more than simply updated the package index, it downloads the files
- Not sure if it's better to reindex the way I've done it or to use your `addPackage` for this purpose

Can we simply use a copy of that function internally?

> On Nov 9, 2014, at 6:17 AM, Andrie <notifications@github.com> wrote:
> 
> In R/update-packages.R:
> 
> > +  }
> > +  update <- NULL
> > +  currentR <- minorR <- Rversion
> > +  minorR[[c(1L, 3L)]] <- 0L
> > +  for (k in 1L:nrow(avlPkgs)) {
> > +    if (avlPkgs[k, "Priority"] %in% "base")
> > +      next
> > +    z <- match(avlPkgs[k, "Package"], available[, "Package"])
> > +    if (is.na(z))
> > +      next
> > +    onRepos <- available[z, ]
> > +    if (package_version(onRepos["Version"]) <= package_version(avlPkgs[k, "Version"]))
> > +      next
> > +    deps <- onRepos["Depends"]
> > +    if (!is.na(deps)) {
> > +      Rdeps <- tools:::.split_dependencies(deps)[["R", exact = TRUE]]
> Nice find of tools:::.split_dependencies. Note that the use of non-exported functions are forbidden on CRAN, so we won't be able to use this function directly.
> 
> —
> Reply to this email directly or view it on GitHub <https://github.com/andrie/miniCRAN/pull/15/files#r20058930>.
> 

--
amc