boring_generators 0.5.0 → 0.10.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (55) hide show
  1. checksums.yaml +4 -4
  2. data/.github/FUNDING.yml +12 -0
  3. data/.github/workflows/ci.yml +7 -1
  4. data/CHANGELOG.md +27 -0
  5. data/Gemfile +5 -0
  6. data/Gemfile.lock +94 -21
  7. data/README.md +27 -6
  8. data/Rakefile +1 -0
  9. data/boring_generators.gemspec +1 -1
  10. data/exe/boring +5 -0
  11. data/lib/boring_generators.rb +1 -0
  12. data/lib/boring_generators/cli.rb +26 -0
  13. data/lib/boring_generators/version.rb +1 -1
  14. data/lib/generators/boring/active_storage/aws/install/install_generator.rb +10 -8
  15. data/lib/generators/boring/active_storage/azure/install/install_generator.rb +9 -7
  16. data/lib/generators/boring/active_storage/google/install/install_generator.rb +9 -7
  17. data/lib/generators/boring/ahoy/install/install_generator.rb +31 -0
  18. data/lib/generators/boring/ahoy/install/templates/README +10 -0
  19. data/lib/generators/boring/audit/install/install_generator.rb +12 -9
  20. data/lib/generators/boring/bullet/install/install_generator.rb +4 -8
  21. data/lib/generators/boring/ci/github_action/install/install_generator.rb +16 -2
  22. data/lib/generators/boring/ci/github_action/install/templates/ci.yml.tt +1 -11
  23. data/lib/generators/boring/devise/install/install_generator.rb +12 -10
  24. data/lib/generators/boring/font_awesome/ruby_gem/install/install_generator.rb +3 -8
  25. data/lib/generators/boring/graphql/install/install_generator.rb +3 -7
  26. data/lib/generators/boring/oauth/base_generator.rb +63 -0
  27. data/lib/generators/boring/oauth/facebook/install/install_generator.rb +36 -0
  28. data/lib/generators/boring/oauth/facebook/install/templates/README +23 -0
  29. data/lib/generators/boring/oauth/facebook/install/templates/omniauth.rb +3 -0
  30. data/lib/generators/boring/oauth/facebook/install/templates/omniauth_callbacks_controller.rb +21 -0
  31. data/lib/generators/boring/oauth/github/install/install_generator.rb +36 -0
  32. data/lib/generators/boring/oauth/github/install/templates/README +23 -0
  33. data/lib/generators/boring/oauth/github/install/templates/omniauth_callbacks_controller.rb +21 -0
  34. data/lib/generators/boring/oauth/google/install/install_generator.rb +36 -0
  35. data/lib/generators/boring/oauth/google/install/templates/README +23 -0
  36. data/lib/generators/boring/oauth/google/install/templates/omniauth_callbacks_controller.rb +21 -0
  37. data/lib/generators/boring/oauth/twitter/install/install_generator.rb +36 -0
  38. data/lib/generators/boring/oauth/twitter/install/templates/README +23 -0
  39. data/lib/generators/boring/oauth/twitter/install/templates/omniauth_callbacks_controller.rb +21 -0
  40. data/lib/generators/boring/payments/stripe/install/install_generator.rb +43 -0
  41. data/lib/generators/boring/payments/stripe/install/templates/README +21 -0
  42. data/lib/generators/boring/payments/stripe/install/templates/controllers/stripe/checkouts_controller.rb +63 -0
  43. data/lib/generators/boring/payments/stripe/install/templates/stripe.rb +1 -0
  44. data/lib/generators/boring/payments/stripe/install/templates/views/stripe/checkouts/create.js.erb +13 -0
  45. data/lib/generators/boring/payments/stripe/install/templates/views/stripe/checkouts/show.html.erb +8 -0
  46. data/lib/generators/boring/pry/install/install_generator.rb +4 -9
  47. data/lib/generators/boring/pundit/install/install_generator.rb +3 -9
  48. data/lib/generators/boring/rubocop/install/install_generator.rb +3 -1
  49. data/lib/generators/boring/simple_form/install/install_generator.rb +4 -8
  50. data/lib/generators/boring/tailwind/install/install_generator.rb +12 -11
  51. data/lib/generators/boring/tailwind/install/templates/README +13 -0
  52. data/lib/generators/boring/twilio/install/install_generator.rb +26 -0
  53. data/lib/generators/boring/twilio/install/templates/README +11 -0
  54. data/lib/generators/boring/twilio/install/templates/twilio.rb +4 -0
  55. metadata +33 -664
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 75b70f624969fe4703d011e6eb9885aec618fa1292ed919610a151257126bbf0
4
- data.tar.gz: e34d25d853079666eeb09c4a5c27b306f4a8a835a8d5e3f300ad7a126eb81b23
3
+ metadata.gz: 0270bea161b8e7aa0cce68a2f79bd8456865f7f0ee00c3fef81b0ecddbfba1e1
4
+ data.tar.gz: 19e58c07ef090636ca05c1e7c620e750994c72e052ae3dc51e6b1887783582cb
5
5
  SHA512:
6
- metadata.gz: 042b85804c5a7fc75f79596d55ab2ca4ec688268781717dbb2d02755bc5b9d40ffe17b60951f46fb2c2365c8560c466b4161a029f2d3da1e8987f6306d1bd6ee
7
- data.tar.gz: a643190096fbd0c4b78e798547219f56d1877e4f91110ff8919448c56a77a7c9a8d4170eadfc70353615e73b886fb6101bfabea290f6b52ad4b815c068096609
6
+ metadata.gz: 1dd9d49410e16f73b13116f490fca9407313bf845f21ce45e403b5e4ced43e7647e0ed52b020f175cae2571ad6b6a5ff16b2ade2d271a338905837c93b58317a
7
+ data.tar.gz: '092146185b12c44adad625d7c67a19253759a4d7b7a8a520ec4b541bf066f49aa98dba50787dc46ad535ad2318c79e31fb6e2fc60d7e14733872948f738ee83a'
@@ -0,0 +1,12 @@
1
+ # These are supported funding model platforms
2
+
3
+ github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4
+ patreon: # Replace with a single Patreon username
5
+ open_collective: boring_generators
6
+ ko_fi: # Replace with a single Ko-fi username
7
+ tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8
+ community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9
+ liberapay: # Replace with a single Liberapay username
10
+ issuehunt: # Replace with a single IssueHunt username
11
+ otechie: # Replace with a single Otechie username
12
+ custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
@@ -11,7 +11,13 @@ jobs:
11
11
  uses: ruby/setup-ruby@v1
12
12
  with:
13
13
  ruby-version: 2.7.0
14
+ bundler-cache: true
15
+ - name: Install Imagemagick
16
+ run: |
17
+ wget https://raw.githubusercontent.com/discourse/discourse_docker/master/image/base/install-imagemagick
18
+ chmod +x install-imagemagick
19
+ sudo ./install-imagemagick
14
20
  - name: Install gems
15
21
  run: bundle install --jobs 4 --retry 3
16
22
  - name: Run tests
17
- run: bundle exec rake test
23
+ run: bundle exec rake test --trace
data/CHANGELOG.md CHANGED
@@ -1,6 +1,31 @@
1
1
  # Changelog
2
2
 
3
3
  ## master (unreleased)
4
+
5
+ ## 0.10.0 (May 26th, 2021)
6
+ * Updates Stripe payment generator. ([@abhaynikam][])
7
+ * Fixes many generators which install ruby gems to not hardcode gem version. ([@abhaynikam][])
8
+
9
+ ## 0.9.0 (April 14th, 2021)
10
+ * Adds Ahoy generator. ([@abhaynikam][])
11
+ * Adds Stripe payment generator. ([@abhaynikam][])
12
+
13
+ ## 0.8.0 (February 28th, 2021)
14
+ * Adds Devise Google Omniauth generator. ([@abhaynikam][])
15
+ * Adds Devise Twitter Omniauth generator. ([@abhaynikam][])
16
+ * Adds Twilio generator. ([@abhaynikam][])
17
+
18
+ ## 0.7.0 (January 30th, 2021)
19
+ * Upgrade the Tailwind CSS generator to support Tailwind V2.0. ([@abhaynikam][])
20
+ * Adds Devise GitHub Omniauth generator. ([@abhaynikam][])
21
+
22
+ ## 0.6.0 (January 10th, 2021)
23
+ * Updates default ruby version of GitHub Actions install generator. ([@jamesglover][])
24
+ * Simplify generated GitHub Actions install ([@jamesglover][])
25
+ * Adds boring generator CLI ([@luathn][])
26
+ * Adds Devise Facebook Omniauth generator. ([@abhaynikam][])
27
+
28
+ ## 0.5.0 (December 20th, 2020)
4
29
  * Adds favicon build generator. ([@abhaynikam][])
5
30
  * Adds Pundit install generator. ([@CiTroNaK][])
6
31
  * Adds GraphQL generator. ([@abhaynikam][])
@@ -34,3 +59,5 @@
34
59
 
35
60
  [@abhaynikam]: https://github.com/abhaynikam
36
61
  [@CiTroNaK]: https://github.com/CiTroNaK
62
+ [@jamesglover]: https://github.com/JamesGlover
63
+ [@luathn]: https://github.com/luathn
data/Gemfile CHANGED
@@ -3,6 +3,11 @@ source "https://rubygems.org"
3
3
  # Specify your gem's dependencies in boring_generators.gemspec
4
4
  gemspec
5
5
 
6
+ gem "rails", "~> 6.0.3.4"
6
7
  gem "rake", "~> 12.0"
7
8
  gem "minitest", "~> 5.0"
8
9
  gem "byebug"
10
+
11
+ platforms :ruby do
12
+ gem "sqlite3", "~> 1.4"
13
+ end
data/Gemfile.lock CHANGED
@@ -1,26 +1,62 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- boring_generators (0.4.0)
4
+ boring_generators (0.9.0)
5
5
  railties
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
- actionpack (6.0.3.4)
11
- actionview (= 6.0.3.4)
12
- activesupport (= 6.0.3.4)
10
+ actioncable (6.0.3.6)
11
+ actionpack (= 6.0.3.6)
12
+ nio4r (~> 2.0)
13
+ websocket-driver (>= 0.6.1)
14
+ actionmailbox (6.0.3.6)
15
+ actionpack (= 6.0.3.6)
16
+ activejob (= 6.0.3.6)
17
+ activerecord (= 6.0.3.6)
18
+ activestorage (= 6.0.3.6)
19
+ activesupport (= 6.0.3.6)
20
+ mail (>= 2.7.1)
21
+ actionmailer (6.0.3.6)
22
+ actionpack (= 6.0.3.6)
23
+ actionview (= 6.0.3.6)
24
+ activejob (= 6.0.3.6)
25
+ mail (~> 2.5, >= 2.5.4)
26
+ rails-dom-testing (~> 2.0)
27
+ actionpack (6.0.3.6)
28
+ actionview (= 6.0.3.6)
29
+ activesupport (= 6.0.3.6)
13
30
  rack (~> 2.0, >= 2.0.8)
14
31
  rack-test (>= 0.6.3)
15
32
  rails-dom-testing (~> 2.0)
16
33
  rails-html-sanitizer (~> 1.0, >= 1.2.0)
17
- actionview (6.0.3.4)
18
- activesupport (= 6.0.3.4)
34
+ actiontext (6.0.3.6)
35
+ actionpack (= 6.0.3.6)
36
+ activerecord (= 6.0.3.6)
37
+ activestorage (= 6.0.3.6)
38
+ activesupport (= 6.0.3.6)
39
+ nokogiri (>= 1.8.5)
40
+ actionview (6.0.3.6)
41
+ activesupport (= 6.0.3.6)
19
42
  builder (~> 3.1)
20
43
  erubi (~> 1.4)
21
44
  rails-dom-testing (~> 2.0)
22
45
  rails-html-sanitizer (~> 1.1, >= 1.2.0)
23
- activesupport (6.0.3.4)
46
+ activejob (6.0.3.6)
47
+ activesupport (= 6.0.3.6)
48
+ globalid (>= 0.3.6)
49
+ activemodel (6.0.3.6)
50
+ activesupport (= 6.0.3.6)
51
+ activerecord (6.0.3.6)
52
+ activemodel (= 6.0.3.6)
53
+ activesupport (= 6.0.3.6)
54
+ activestorage (6.0.3.6)
55
+ actionpack (= 6.0.3.6)
56
+ activejob (= 6.0.3.6)
57
+ activerecord (= 6.0.3.6)
58
+ marcel (~> 1.0.0)
59
+ activesupport (6.0.3.6)
24
60
  concurrent-ruby (~> 1.0, >= 1.0.2)
25
61
  i18n (>= 0.7, < 2)
26
62
  minitest (~> 5.1)
@@ -28,39 +64,74 @@ GEM
28
64
  zeitwerk (~> 2.2, >= 2.2.2)
29
65
  builder (3.2.4)
30
66
  byebug (11.1.3)
31
- concurrent-ruby (1.1.7)
67
+ concurrent-ruby (1.1.8)
32
68
  crass (1.0.6)
33
- erubi (1.9.0)
34
- i18n (1.8.5)
69
+ erubi (1.10.0)
70
+ globalid (0.4.2)
71
+ activesupport (>= 4.2.0)
72
+ i18n (1.8.10)
35
73
  concurrent-ruby (~> 1.0)
36
- loofah (2.7.0)
74
+ loofah (2.9.1)
37
75
  crass (~> 1.0.2)
38
76
  nokogiri (>= 1.5.9)
77
+ mail (2.7.1)
78
+ mini_mime (>= 0.1.1)
79
+ marcel (1.0.1)
39
80
  method_source (1.0.0)
40
- mini_portile2 (2.4.0)
41
- minitest (5.14.2)
42
- nokogiri (1.10.10)
43
- mini_portile2 (~> 2.4.0)
81
+ mini_mime (1.1.0)
82
+ mini_portile2 (2.5.0)
83
+ minitest (5.14.4)
84
+ nio4r (2.5.7)
85
+ nokogiri (1.11.3)
86
+ mini_portile2 (~> 2.5.0)
87
+ racc (~> 1.4)
88
+ racc (1.5.2)
44
89
  rack (2.2.3)
45
90
  rack-test (1.1.0)
46
91
  rack (>= 1.0, < 3)
92
+ rails (6.0.3.6)
93
+ actioncable (= 6.0.3.6)
94
+ actionmailbox (= 6.0.3.6)
95
+ actionmailer (= 6.0.3.6)
96
+ actionpack (= 6.0.3.6)
97
+ actiontext (= 6.0.3.6)
98
+ actionview (= 6.0.3.6)
99
+ activejob (= 6.0.3.6)
100
+ activemodel (= 6.0.3.6)
101
+ activerecord (= 6.0.3.6)
102
+ activestorage (= 6.0.3.6)
103
+ activesupport (= 6.0.3.6)
104
+ bundler (>= 1.3.0)
105
+ railties (= 6.0.3.6)
106
+ sprockets-rails (>= 2.0.0)
47
107
  rails-dom-testing (2.0.3)
48
108
  activesupport (>= 4.2.0)
49
109
  nokogiri (>= 1.6)
50
110
  rails-html-sanitizer (1.3.0)
51
111
  loofah (~> 2.3)
52
- railties (6.0.3.4)
53
- actionpack (= 6.0.3.4)
54
- activesupport (= 6.0.3.4)
112
+ railties (6.0.3.6)
113
+ actionpack (= 6.0.3.6)
114
+ activesupport (= 6.0.3.6)
55
115
  method_source
56
116
  rake (>= 0.8.7)
57
117
  thor (>= 0.20.3, < 2.0)
58
118
  rake (12.3.3)
59
- thor (1.0.1)
119
+ sprockets (4.0.2)
120
+ concurrent-ruby (~> 1.0)
121
+ rack (> 1, < 3)
122
+ sprockets-rails (3.2.2)
123
+ actionpack (>= 4.0)
124
+ activesupport (>= 4.0)
125
+ sprockets (>= 3.0.0)
126
+ sqlite3 (1.4.2)
127
+ thor (1.1.0)
60
128
  thread_safe (0.3.6)
61
- tzinfo (1.2.7)
129
+ tzinfo (1.2.9)
62
130
  thread_safe (~> 0.1)
63
- zeitwerk (2.4.0)
131
+ websocket-driver (0.7.3)
132
+ websocket-extensions (>= 0.1.0)
133
+ websocket-extensions (0.1.5)
134
+ zeitwerk (2.4.2)
64
135
 
65
136
  PLATFORMS
66
137
  ruby
@@ -69,7 +140,9 @@ DEPENDENCIES
69
140
  boring_generators!
70
141
  byebug
71
142
  minitest (~> 5.0)
143
+ rails (~> 6.0.3.4)
72
144
  rake (~> 12.0)
145
+ sqlite3 (~> 1.4)
73
146
 
74
147
  BUNDLED WITH
75
148
  2.1.4
data/README.md CHANGED
@@ -32,22 +32,27 @@ Or install it yourself as:
32
32
 
33
33
  $ gem install boring_generators
34
34
 
35
+ And then you can use it this way:
36
+
37
+ $ boring generate boring:simple_form:install --css_framework=<css_framework>
38
+ $ boring g boring:pry:install
39
+
35
40
  ## Usage
36
41
 
37
42
  The boring generator introduces following generators:
38
- - Install Tailwind CSS: `rails generate boring:tailwind:install`
39
- - Install Bootstrap: `rails generate boring:bootstrap:install`
43
+ - [Install Tailwind CSS](https://www.boringgenerators.com/blog/2020-10-18-install-tailwind/): `rails generate boring:tailwind:install`
44
+ - [Install Bootstrap](https://www.boringgenerators.com/blog/2020-11-15-install-bootstrap/): `rails generate boring:bootstrap:install`
40
45
  - Install JQuery: `rails generate boring:jquery:install`
41
- - Install FontAwesome via Yarn: `rails generate boring:font_awesome:yarn:install`
42
- - Install FontAwesome via RubyGems: `rails generate boring:font_awesome:ruby_gem:install`
46
+ - [Install FontAwesome via Yarn](https://www.boringgenerators.com/blog/2021-02-28-install-fontawesome-yarn/): `rails generate boring:font_awesome:yarn:install`
47
+ - [Install FontAwesome via RubyGems](https://www.boringgenerators.com/blog/2021-02-23-install-fontawesome/): `rails generate boring:font_awesome:ruby_gem:install`
43
48
  - Install Bullet: `rails generate boring:bullet:install`
44
49
  - Install Audit gems(bundler-audit, ruby_audit): `rails generate boring:audit:install`
45
50
  - Install Pry gems for easy debugging: `rails generate boring:pry:install`
46
51
  - Install Active Storage for Google Cloud Service: `rails generate boring:active_storage:google:install`
47
52
  - Install Active Storage for AWS: `rails generate boring:active_storage:aws:install`
48
53
  - Install Active Storage for Azure: `rails generate boring:active_storage:azure:install`
49
- - Install CircleCI: `rails generate boring:ci:circleci:install --repository_name=<name> --ruby_version=<version>`
50
- - Install GitHub Actions: `rails generate boring:ci:github_action:install --repository_name=<name> --ruby_version=<version>`
54
+ - [Install CircleCI](https://www.boringgenerators.com/blog/2021-01-02-configure-circleci/): `rails generate boring:ci:circleci:install --repository_name=<name> --ruby_version=<version>`
55
+ - [Install GitHub Actions](https://www.boringgenerators.com/blog/2020-12-17-configure-github-actions/): `rails generate boring:ci:github_action:install --repository_name=<name> --ruby_version=<version>`
51
56
  - Install Travis CI: `rails generate boring:ci:travisci:install --ruby_version=<version>`
52
57
  - Install Rubocop: `rails generate boring:rubocop:install --ruby_version=<version>`
53
58
  - Build Favicon: `rails generate boring:favicon:build --application_name=<application_name> --favico_letter=<favico_letter> --primary_color=<color>`
@@ -55,11 +60,27 @@ The boring generator introduces following generators:
55
60
  - Install GraphQL: `rails generate boring:graphql:install`
56
61
  - Install SimpleForm: `rails generate boring:simple_form:install --css_framework=<css_framework>`
57
62
  - Install Devise: `rails generate boring:devise:install`
63
+ - [Install Devise Facebook Omniauth](https://www.boringgenerators.com/blog/2021-02-07-install-oauth-facbook/): `rails generate boring:oauth:facebook:install`
64
+ - Install Devise GitHub Omniauth: `rails generate boring:oauth:github:install`
65
+ - Install Devise Google Omniauth: `rails generate boring:oauth:google:install`
66
+ - Install Devise Twitter Omniauth: `rails generate boring:oauth:twitter:install`
67
+ - Install Twilio: `rails generate boring:twilio:install`
68
+ - Install Ahoy: `rails generate boring:ahoy:install`
69
+ - Install Stripe: `rails generate boring:payments:stripe:install`
70
+
71
+ ## Screencasts
72
+
73
+ - [How to use Boring Generators](https://www.youtube.com/watch?v=9vaK9nDMbU8) by [Yaroslav Shmarov](https://twitter.com/yarotheslav)
58
74
 
59
75
  ## Development
60
76
 
61
77
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
62
78
 
79
+ You can also run specific test cases using following commands:
80
+ ```
81
+ bundle exec ruby -w -Itest test/generators/tailwind_install_generator_test.rb
82
+ ```
83
+
63
84
  To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
64
85
 
65
86
  ## Contributing
data/Rakefile CHANGED
@@ -5,6 +5,7 @@ Rake::TestTask.new(:test) do |t|
5
5
  t.libs << "test"
6
6
  t.libs << "lib"
7
7
  t.test_files = FileList["test/**/*_test.rb"]
8
+ t.warning = false
8
9
  end
9
10
 
10
11
  task :default => :test
@@ -27,5 +27,5 @@ Gem::Specification.new do |spec|
27
27
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
28
28
  spec.require_paths = ["lib"]
29
29
 
30
- spec.add_dependency 'railties'
30
+ spec.add_dependency "railties"
31
31
  end
data/exe/boring ADDED
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require_relative "../lib/boring_generators/cli"
4
+
5
+ BoringGenerators::CLI.start(ARGV)
@@ -1,4 +1,5 @@
1
1
  require "boring_generators/version"
2
+ require 'bundler'
2
3
 
3
4
  module BoringGenerators
4
5
  class Error < StandardError; end
@@ -0,0 +1,26 @@
1
+ # frozen_string_literal: true
2
+ require "rails/generators"
3
+ require_relative "../boring_generators"
4
+
5
+ module BoringGenerators
6
+ class CLI < Thor
7
+ map "g" => :generate
8
+ map %w(--version -v) => :__print_version
9
+
10
+ desc "generate GENERATOR [options]", "Add gem to the application"
11
+ def generate(generator, *options)
12
+ Rails::Generators.invoke(generator, options)
13
+ end
14
+
15
+ desc "--version, -v", "Print gem version"
16
+ def __print_version
17
+ puts "Boring generators #{BoringGenerators::VERSION}"
18
+ end
19
+
20
+ class << self
21
+ def exit_on_failure?
22
+ true
23
+ end
24
+ end
25
+ end
26
+ end
@@ -1,3 +1,3 @@
1
1
  module BoringGenerators
2
- VERSION = "0.5.0"
2
+ VERSION = "0.10.0"
3
3
  end
@@ -15,14 +15,16 @@ module Boring
15
15
  end
16
16
 
17
17
  def add_aws_to_the_application
18
- say "Adding AWS gem", :green
19
- aws_gem_content = <<~RUBY
20
- \n
21
- # for AWS Service
22
- gem "aws-sdk-s3", require: false
23
- RUBY
24
- append_to_file "Gemfile", aws_gem_content
25
- run "bundle install"
18
+ Bundler.with_unbundled_env do
19
+ say "Adding AWS gem", :green
20
+ aws_gem_content = <<~RUBY
21
+ \n
22
+ # for AWS Service
23
+ gem "aws-sdk-s3", require: false
24
+ RUBY
25
+ append_to_file "Gemfile", aws_gem_content
26
+ run "bundle install"
27
+ end
26
28
  end
27
29
 
28
30
  def add_configuration_to_production
@@ -16,13 +16,15 @@ module Boring
16
16
 
17
17
  def add_azure_to_the_application
18
18
  say "Adding mircosoft azure gem", :green
19
- azure_gem_content = <<~RUBY
20
- \n
21
- # for Azure Service
22
- gem "azure-storage-blob", require: false
23
- RUBY
24
- append_to_file "Gemfile", azure_gem_content
25
- run "bundle install"
19
+ Bundler.with_unbundled_env do
20
+ azure_gem_content = <<~RUBY
21
+ \n
22
+ # for Azure Service
23
+ gem "azure-storage-blob", require: false
24
+ RUBY
25
+ append_to_file "Gemfile", azure_gem_content
26
+ run "bundle install"
27
+ end
26
28
  end
27
29
 
28
30
  def add_configuration_to_production
@@ -16,13 +16,15 @@ module Boring
16
16
 
17
17
  def add_google_cloud_storage_to_the_application
18
18
  say "Adding google cloud storage gem", :green
19
- google_cloud_storage_gem_content = <<~RUBY
20
- \n
21
- # for Google Cloud Storage Service
22
- gem "google-cloud-storage", require: false
23
- RUBY
24
- append_to_file "Gemfile", google_cloud_storage_gem_content
25
- run "bundle install"
19
+ Bundler.with_unbundled_env do
20
+ google_cloud_storage_gem_content = <<~RUBY
21
+ \n
22
+ # for Google Cloud Storage Service
23
+ gem "google-cloud-storage", require: false
24
+ RUBY
25
+ append_to_file "Gemfile", google_cloud_storage_gem_content
26
+ run "bundle install"
27
+ end
26
28
  end
27
29
 
28
30
  def add_configuration_to_production