Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

$ gem install ignores -v, -r, -l for local .gem files #339

Closed
donv opened this Issue May 28, 2012 · 8 comments

Comments

Projects
None yet
5 participants
Contributor

donv commented May 28, 2012

If you try to install a gem with a version specification ( -v version ), any local gem with a matching name is installed. Local gems should only be installed if they match the version requirement given.

This is related to Issue #170.

@ghost ghost assigned drbrain Jun 5, 2012

Contributor

donv commented Sep 16, 2012

The -r flag is also not respected when there is a local gem file present.

Contributor

raggi commented Sep 24, 2012

Example:

~ % gem fetch rack
Fetching: rack-1.4.1.gem (100%)
Downloaded rack-1.4.1
~ % gem install rack -v 1.3.2
Successfully installed rack-1.4.1
1 gem installed
~ % gem install rack -r -v 1.3.2
Successfully installed rack-1.4.1
1 gem installed
~ % rm rack-1.4.1.gem 
~ % gem install rack -r -v 1.3.2
Fetching: rack-1.3.2.gem (100%)
Successfully installed rack-1.3.2
1 gem installed
Owner

evanphx commented Sep 24, 2012

Could you check on master? I've changes the gem finding logic so I'm thinking it's probably fixed.

On Sep 23, 2012, at 5:07 PM, James Tucker notifications@github.com wrote:

Example:

~ % gem fetch rack
Fetching: rack-1.4.1.gem (100%)
Downloaded rack-1.4.1
~ % gem install rack -v 1.3.2
Successfully installed rack-1.4.1
1 gem installed
~ % gem install rack -r -v 1.3.2
Successfully installed rack-1.4.1
1 gem installed
~ % rm rack-1.4.1.gem
~ % gem install rack -r -v 1.3.2
Fetching: rack-1.3.2.gem (100%)
Successfully installed rack-1.3.2
1 gem installed

Reply to this email directly or view it on GitHub.

Contributor

donv commented Sep 24, 2012

Will do.

Contributor

donv commented Sep 24, 2012

Looks good. The -r, -l, and -v flags work.

Contributor

donv commented Sep 24, 2012

Installing a pre-release gem locally using -l and -v to select is failing.

Owner

drbrain commented Nov 27, 2012

@evanphx seems we have some corners that aren't resolved yet, can you check?

@krainboltgreene krainboltgreene changed the title from No version checking when installing locally to gem install ignores -v, -r, -l for local .gem files Jan 1, 2016

@krainboltgreene krainboltgreene changed the title from gem install ignores -v, -r, -l for local .gem files to $ gem install ignores -v, -r, -l for local .gem files Jan 1, 2016

@krainboltgreene krainboltgreene self-assigned this Jan 1, 2016

Member

krainboltgreene commented Jan 1, 2016

Looks like this got completely solved! I tested locally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment