Description Usage Arguments Value Author(s) Examples
Unzip a zip archive file
Unzip a zip archive file, crossplatform - ie on mac, windows and linux
If zip.filename
is a URL, it is first downlaoded to dest
On MacOS, this function removes the hidden ._ files, and __MACOSX folder
which get created by the Finder>Create Archive program on some Mac platforms.
As with all zip files, if the zipped files are not within a subdirectory,
they will all be extracted to destdir
, so you may want to ensure
that the destdir
is clean and empty
1 | crossplatform.unzip(zip.filename, dest = NULL, verbose = FALSE)
|
zip.filename |
the path, or url to a single zip file |
dest |
the path to the destination directory. If |
verbose |
logical: noisy? |
a character vector of paths to the files that were unzipped.
Mark Cowley, 2010-01-08
1 2 3 4 5 6 7 8 9 | ## Not run:
# f <- "http://mirror.aarnet.edu.au/pub/CRAN/bin/windows/contrib/r-release/sos_1.3-1.zip"
f <- "http://cran.r-project.org/bin/windows/contrib/r-release/sos_1.3-1.zip"
# cran.mirror <- getOption("repos", default="http://cran.r-project.org")
# f <- paste(cran.mirror, "bin/windows/contrib/r-release/sos_1.3-1.zip", sep="/")
files <- crossplatform.unzip(f, "/tmp")
files
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.