Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename gem from bcrypt-ruby to bcrypt #86

Merged
merged 2 commits into from Feb 21, 2014

Conversation

sferik
Copy link
Contributor

@sferik sferik commented Dec 18, 2013

It makes sense for this repository to be named bcrypt-ruby, to avoid ambiguity with other bcrypt libraries, but the gem name need not include -ruby, since the rubygems package manager is tightly coupled to the Ruby language. Just as the sqlite3-ruby gem was renamed to sqlite, this package’s name should just be bcrypt.

This also increases consistency between the library’s name and the way it is required.

require 'bcrypt'

I’ve also removed links to the old RubyForge project, which no longer work.

@tjschuck
Copy link
Collaborator

@tmm1 @codahale I'm going to move forward with this and push a new version of the gem up now unless you have any fundamental problems with this.

I'll also push a new dummy version of the gem up to the old name that depends on the new name for backwards compatibility, with a post-install message about the change.

@tjschuck tjschuck merged commit aadbef4 into bcrypt-ruby:master Feb 21, 2014
@sferik
Copy link
Contributor Author

sferik commented Feb 21, 2014

Awesome! Thank you. 😄

@tjschuck
Copy link
Collaborator

Okay, gem has been renamed to just bcrypt and pushed up to RubyGems: https://rubygems.org/gems/bcrypt

@tenderlove @tmm1 @codahale You've all been added as owners of the new gem as well.

A new dummy version of bcrypt-ruby has also been pushed up that has bcrypt as a dependency for backwards compatibility, with a post-install message:

$ gem install bcrypt-ruby
Fetching: bcrypt-3.1.3.gem (100%)
Building native extensions.  This could take a while...
Successfully installed bcrypt-3.1.3
Fetching: bcrypt-ruby-3.1.3.gem (100%)
Building native extensions.  This could take a while...

#######################################################

The bcrypt-ruby gem has changed it's name to just bcrypt.  Instead of
installing `bcrypt-ruby`, you should install `bcrypt`.  Please update your
dependencies accordingly.

#######################################################

Successfully installed bcrypt-ruby-3.1.3
2 gems installed

@tjschuck
Copy link
Collaborator

@tenderlove @sferik @tmm1 @codahale Also, please consider retweeting this announcement if that's your thing: https://twitter.com/tjschuck/status/436971394333966336

Thanks!

@nirvdrum
Copy link

@tjschuck I couldn't find the source for the dummy gem so I couldn't issue a pull request. But a tiny change is "it's name" should be "its name" in the post-install message.

@accelecon
Copy link

It looks like the bcrypt-dummy gem defines the BCrypt constant and clobbers the real one.

@tjschuck
Copy link
Collaborator

@nirvdrum Thanks -- will fix in a jiff.

@accelecon I'm not seeing that happen... more info?

@accelecon
Copy link

It could be my fault; I'm still looking into it. My Gemfile.lock has:

    bcrypt (3.1.3)
    bcrypt (3.1.3-java)
    bcrypt-ruby (3.1.3)
      bcrypt (>= 3.1.3)
    bcrypt-ruby (3.1.3-java)
      bcrypt (>= 3.1.3)

And in rails c, I get:

irb(main):001:0> defined?(BCrypt)
=> "constant"
irb(main):002:0> defined?(BCrypt::Password)
=> nil
irb(main):003:0> 

@tjschuck
Copy link
Collaborator

@nirvdrum Just pushed a new version of the dummy gem to fix the typo. Thanks again.

@accelecon Here's what I've got:

$ gem install bcrypt-ruby
 [...]
2 gems installed
$ irb
irb(main):001:0> require 'bcrypt'
=> true
irb(main):002:0> defined?(BCrypt)
=> "constant"
irb(main):003:0> defined?(BCrypt::Password)
=> "constant"

Lemme know if you figure out your case, or if you have steps to reproduce.

@nirvdrum
Copy link

@tjschuck Awesome. Thanks for the quick turnaround.

@tjschuck
Copy link
Collaborator

@accelecon Jump over to #89 if you have any followup on the issue.

calebhearth added a commit to halogenandtoast/oath that referenced this pull request Feb 24, 2014
calebhearth added a commit to thoughtbot/clearance that referenced this pull request Feb 24, 2014
calebhearth added a commit to thoughtbot/clearance that referenced this pull request Feb 25, 2014
tiseheaini pushed a commit to tiseheaini/campo that referenced this pull request Jul 30, 2014
instructure-gerrit pushed a commit to instructure/canvas-lms that referenced this pull request Oct 31, 2016
See bcrypt-ruby/bcrypt-ruby#86

Test plan:
* specs pass

Change-Id: Icb8aaaa332a6b3d9be82fb3ad76e234b66801480
Reviewed-on: https://gerrit.instructure.com/93999
Reviewed-by: Derek Bender <djbender@instructure.com>
Reviewed-by: Shahbaz Javeed <sjaveed@instructure.com>
Tested-by: Jenkins
Product-Review: Neil Gupta <ngupta@instructure.com>
QA-Review: Neil Gupta <ngupta@instructure.com>
schleuderrr pushed a commit to schleuder/schleuder that referenced this pull request Feb 4, 2021
schleuderrr pushed a commit to schleuder/schleuder that referenced this pull request Mar 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants