Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how do I speed up a bundle install?

Sometimes I have to run bundle install 10 times in an hour just to the right gems. Presumably this bit:

Fetching source index for http://rubygems.org/

Is only necessary periodically, but definitely doesn't need to be done 10 times in one hour, right? Is there any way to skip this, and use a local cache?

Any help appreciated. Seriously bogging me down...

like image 367
pixelearth Avatar asked Mar 20 '26 07:03

pixelearth


1 Answers

To avoid updating sources:

gem install my_gem --no-update-sources

You could setup a local gem repository, and specify local file paths for your gems in Gemfile.

gem 'my_gem', '1.0.0', :path => '/path/to/my_gem'

You could also set up a local rubygems server, which could be used through:

source 'http://127.0.0.1:8080' # your gem server

like image 166
Adam Eberlin Avatar answered Mar 22 '26 20:03

Adam Eberlin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!