Reputation:
I've created and pushed a gem to rubygems. I can install using:
'gem install mygem'
=> mygem installed
..and..
# Gemfile
gem 'mygem', git: '[email protected]:me/mygem.git'
But if I put only gem 'mygem'
in my Gemfile and bundle install
, I receive this error:
Fetching gem metadata from https://rubygems.org/.......
Fetching gem metadata from https://rubygems.org/..
Could not find gem 'mygem (>= 0) ruby' in the gems available on this machine.
The gem was pushed to rubygems 3pm GMT. Not sure if the metadata bundler is fetching is the same as metadata used with gem install
.
Before adding mygem
to the Gemfile, I have successfully bundle install
30 other gems. Also note the available on this machine
part. Why not in any sources
like I've seen many times before?
Bundler version 1.2.2
Upvotes: 3
Views: 233
Reputation: 869
Correction: after some time my just added gem appeared where bundler looks for them. Apparently gem lists bundler use are being updated rarely. So, with gems under development, just use :git notation in the Gemfile:
gem 'iso_3166', :git => '[email protected]:sergeych/iso_countries.git'
Upvotes: 1