bundle install
$ bundle install [--binstubs=PATH] [--clean] [--deployment] [--frozen]
[--full-index] [--gemfile=FILE] [--local] [--no-cache]
[--no-prune] [--path=PATH] [--quiet] [--shebang=STRING]
[--standalone=ARRAY] [--system] [--without=GROUP GROUP]
Options:
--binstubs
: Generate bin stubs for bundled gems to ./bin
--clean
: Run bundle clean automatically after install
--deployment
: Install using defaults tuned for deployment environments
--frozen
: Do not allow the Gemfile.lock to be updated after this install
--full-index
: Use the rubygems modern index instead of the API endpoint
--gemfile
: Use the specified gemfile instead of Gemfile
--local
: Do not attempt to fetch gems remotely and use the gem cache instead
--no-cache
: Don't update the existing gem cache.
--no-prune
: Don't remove stale gems from the cache.
--path
: Specify a different path than the system default ($BUNDLE_PATH or $GEM_HOME). Bundler will remember this value for future installs on this machine
--quiet
: Only output warnings and errors.
--shebang
: Specify a different shebang executable name than the default (usually 'ruby')
--standalone
: Make a bundle that can work without the Bundler runtime
--system
: Install to the system location ($BUNDLE_PATH or $GEM_HOME) even if the bundle was previously installed somewhere else for this application
--without
: Exclude gems that are part of the specified named group.
--jobs
: Install gems using parallel workers.
--retry
: Retry network and git requests that have failed.
Gems will be installed to your default system location for gems. If your system gems are stored in a root-owned location (such as in Mac OSX), bundle will ask for your root password to install them there.
While installing gems, Bundler will check vendor/cache
and then
your system's gems. If a gem isn't cached or installed, Bundler will try to
install it from the sources you have declared in your Gemfile.
The --system
option is the default. Pass it to switch back after
using the --path
option as described below.
vendor/bundle
.
$ bundle install --path vendor/bundle
bundle
commands or calls to Bundler.setup
or
Bundler.require
will remember this location.
$ bundle install --without development test
$ bundle install --deployment
The --deployment
flag activates a number of deployment-friendly
conventions:
- Isolate all gems into
vendor/bundle
- Require an up-to-date
Gemfile.lock
-
If
bundle package
was run, do not fetch gems from rubygems.org. Instead, only use gems in the checked invendor/cache
$ bundle install --jobs 4
$ bundle install --retry 3