bundler
Ruby dependency manager
TLDR
Install dependencies from Gemfile
$ bundle install
Add a gem to Gemfile$ bundle add [gem]
Update all gems$ bundle update
Update specific gem$ bundle update [gem]
Execute command with bundled gems$ bundle exec [command]
Initialize new Gemfile$ bundle init
Show installed gems$ bundle list
Check for security vulnerabilities$ bundle audit
SYNOPSIS
bundle command [options] [arguments]
DESCRIPTION
bundler manages Ruby application dependencies by tracking and installing exact gem versions needed. It ensures consistent environments across development, staging, and production by using a Gemfile and Gemfile.lock.
Since Ruby 2.6, Bundler is part of Ruby's standard library.
PARAMETERS
--no-color
Disable colored output--verbose
Enable verbose output--path directory
Install gems to specified directory--without groups
Exclude gem groups from installation--deployment
Install in deployment mode
CONFIGURATION
Gemfile
Specifies Ruby gem dependencies for the project. Located in the project root directory..bundle/config
Per-project Bundler configuration including install paths, without groups, and deployment settings. Also reads from ~/.bundle/config for global defaults.
COMMANDS
install
Install gems specified in Gemfileupdate
Update gems to latest versions within constraintsexec
Execute command in context of bundleadd
Add gem to Gemfile and installremove
Remove gem from Gemfileinit
Generate a simple Gemfilelist
Show all installed gemsshow
Show gem installation locationcheck
Verify all dependencies are installedclean
Remove unused gemsdoctor
Display warnings about common problemsgem
Create a simple gem skeletonplatform
Display platform compatibility information
CAVEATS
Always use bundle exec when running gem executables to ensure correct versions. The Gemfile.lock should be committed to version control. Running bundle update without arguments may introduce breaking changes.
