🔥 Simple package manager for R
Get the next generation version
Specify all your packages in one place
package("plyr")
package("reshape2", "1.4.0")
package("forecast", github="robjhyndman/forecast")
Install them with a single command, and include them all at once - no need for library
calls.
Jetpack is lightweight and uses a secure CRAN mirror by default.
Add Jetpack to your project
cd path/to/your/project
curl -LsO https://raw.github.com/ankane/jetpack-v1/master/jetpack.R
Create packages.R
and add your packages
package("plyr")
package("reshape2", "1.4.0")
package("forecast", github="robjhyndman/forecast")
Install packages
Rscript jetpack.R
Optional: Instead of including packages individually, you can add these lines to the start of your scripts
source("jetpack.R")
jetpack.require()
Add the package to packages.R
package("inTrees")
and run
Rscript jetpack.R
That’s all there is to it!
Create an init.R
with:
source("jetpack.R")
jetpack.install()
The first deploy can take a few minutes, but future deploys should be very fast.
Be sure to check jetpack.R
and packages.R
into version control.
If deploying your project, you can run Rscript jetpack.R
on every deploy to keep your servers up-to-date. This command is extremely fast if all packages are installed.
Jetpack is simple.
- No additional dependency resolution
- Libraries are installed globally
- Versioning is not supported
For more advanced projects, check out
Update packages
Rscript jetpack.R update
Update a single package
Rscript jetpack.R update plyr
More verbosity
VERBOSE=1 Rscript jetpack.R
Specify a mirror in packages.R
with
repo("https://cran.r-project.org/")
To get the latest version, run
cd path/to/your/project
curl -LsO https://raw.github.com/ankane/jetpack-v1/master/jetpack.R
Everyone is encouraged to help improve this project. Here are a few ways you can help:
- Report bugs
- Fix bugs and submit pull requests
- Write, clarify, or fix documentation
- Suggest or add new features