Get the latest tech news

Hunting for Gems: How Ruby's package management system evolved


It’s time for another installment in our series on loading code in Rails. We have already discussed: - Part 1 - Loading Files In Ruby - Part 2 - Loading Files in Rails (using Ruby’s in-built mechansims and the Autoloader) But so far, we’ve not talked about gems.

Using other people’s code instead of writing your own saves a lot of time, so it’s an important part of the story. Through a clever hack[^the-clever-hack], Ruby will pass over control to RubyGems and ask it to add a folder containing this gem to the$LOAD_PATH. Solving this problem would require the final piece in our Ruby dependency management story.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of ruby

ruby

Photo of Gems

Gems

Related news:

News photo

Incremental Garbage Collection in Ruby 2.2 (2015)

News photo

Ruby on Rails continues to thrive

News photo

How to use Gemini's Gems to create your own custom AI assistants