1BUNDLE-ADD(1) BUNDLE-ADD(1)
2
3
4
6 bundle-add - Add gem to the Gemfile and run bundle install
7
9 bundle add GEM_NAME [--group=GROUP] [--version=VERSION]
10 [--source=SOURCE] [--git=GIT] [--github=GITHUB] [--branch=BRANCH]
11 [--ref=REF] [--skip-install] [--strict] [--optimistic]
12
14 Adds the named gem to the Gemfile and run bundle install. bundle in‐
15 stall can be avoided by using the flag --skip-install.
16
17 Example:
18
19 bundle add rails
20
21 bundle add rails --version "< 3.0, > 1.1"
22
23 bundle add rails --version "~> 5.0.0" --source "https://gems.exam‐
24 ple.com" --group "development"
25
26 bundle add rails --skip-install
27
28 bundle add rails --group "development, test"
29
31 --version, -v
32 Specify version requirements(s) for the added gem.
33
34 --group, -g
35 Specify the group(s) for the added gem. Multiple groups should
36 be separated by commas.
37
38 --source, , -s
39 Specify the source for the added gem.
40
41 --git Specify the git source for the added gem.
42
43 --github
44 Specify the github source for the added gem.
45
46 --branch
47 Specify the git branch for the added gem.
48
49 --ref Specify the git ref for the added gem.
50
51 --skip-install
52 Adds the gem to the Gemfile but does not install it.
53
54 --optimistic
55 Adds optimistic declaration of version
56
57 --strict
58 Adds strict declaration of version
59
60
61
62
63 December 2021 BUNDLE-ADD(1)