"Vendor Everything" still applies

1,767 views

Published on

This talk is a quick lesson on some of the conventions I use and as they relate to Bundler and RVM.

As a consultant, I jump between a lot of different Ruby projects from day to day. Some are my own; some are owned by others. Some are greenfield; some are legacy. Sometimes, I’m the sole developer; sometimes, I’m working with a team.

There’s nothing more frustrating than jumping on an existing project only to fall into dependency hell when your first goal is just a passing test suite. Dependencies can be quite difficult to manage, and fortunately, we have some great tools like Bundler and RVM to help out. The problem, however, is that conventions surrounding these tools aren’t yet settled.

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
1,767
On SlideShare
0
From Embeds
0
Number of Embeds
51
Actions
Shares
0
Downloads
8
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

"Vendor Everything" still applies

  1. 1. “Vendor Everything” Ryan McGeary http://ryan.mcgeary.org Still Applies @rmm5t
  2. 2. e m s e m / g g . g o r f iv e nd c on
  3. 3. WHY?
  4. 4. Check in your .rvmrcrvm ruby-1.9.2
  5. 5. RVM GemsetsAre Overrated
  6. 6. Let Bundler Follow the --path$ bundle install --path vendor$ echo vendor/ruby >> .gitignore
  7. 7. Package Your Gems in vendor/cache$ bundle package
  8. 8. Help!alias b="bundle"alias bi="b install --path vendor"alias bu="b update"alias be="b exec"alias binit="bi && b package && ignore_vendor_ruby"
  9. 9. .!"" .gitignore!"" .rvmrc!"" Gemfile!"" Gemfile.lock#"" vendor !"" cache $   !"" coffee-script-2.2.0.gem $   !"" coffee-script-source-1.1.0.gem $   !"" execjs-0.4.0.gem $   #"" multi_json-1.0.2.gem #"" ruby #"" 1.9.1 !"" bin !"" cache !"" doc !"" gems #"" specifications
  10. 10. .!"" .gitignore!"" .rvmrc!"" Gemfile!"" Gemfile.lock#"" vendor !"" cache $   !"" coffee-script-2.2.0.gem $   !"" coffee-script-source-1.1.0.gem $   !"" execjs-0.4.0.gem $   #"" multi_json-1.0.2.gem #"" ruby #"" 1.9.1 !"" bin !"" cache !"" doc !"" gems #"" specifications
  11. 11. .!"" .gitignore!"" .rvmrc!"" Gemfile!"" Gemfile.lock#"" vendor !"" cache $   !"" coffee-script-2.2.0.gem $   !"" coffee-script-source-1.1.0.gem $   !"" execjs-0.4.0.gem $   #"" multi_json-1.0.2.gem #"" ruby #"" 1.9.1 !"" bin !"" cache !"" doc !"" gems #"" specifications
  12. 12. .!"" .gitignore!"" .rvmrc!"" Gemfile!"" Gemfile.lock#"" vendor !"" cache $   !"" coffee-script-2.2.0.gem $   !"" coffee-script-source-1.1.0.gem $   !"" execjs-0.4.0.gem ven dor $   #"" multi_json-1.0.2.gem --p ath #"" ruby sta ll #"" 1.9.1 le in !"" binund b !"" cache !"" doc !"" gems #"" specifications
  13. 13. .!"" .gitignore!"" .rvmrc!"" Gemfile!"" Gemfile.lock#"" vendor ack age !"" cache dl e p bun $   !"" coffee-script-2.2.0.gem $   !"" coffee-script-source-1.1.0.gem $   !"" execjs-0.4.0.gem $   #"" multi_json-1.0.2.gem #"" ruby #"" 1.9.1 !"" bin !"" cache !"" doc !"" gems #"" specifications
  14. 14. Ryan McGearyryan.mcgeary.org @rmm5t ryan@mcgeary.orgMcGeary Consulting Group

×