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

gem bump tags the wrong version #79

Open
idoa01 opened this issue Mar 4, 2019 · 7 comments
Open

gem bump tags the wrong version #79

idoa01 opened this issue Mar 4, 2019 · 7 comments

Comments

@idoa01
Copy link

idoa01 commented Mar 4, 2019

Hi, I'm trying to use the gem like this: gem bump --tag --skip-ci --push --version patch
my current version is 0.0.1 and I'm bumping to 0.1.0
I'm expecting the tag to be set to 'v0.1.0' but instead I'm getting this output (and the tag created is the same):

bump my-gem 0.0.1 0.1.0
version lib/my-gem/version.rb 0.0.1 0.1.0
git_add lib/my-gem/version.rb
git_commit "Bump my-gem to 0.1.0 [skip ci]"
[master 128a501] Bump my-gem to 0.1.0 [skip ci]
 1 file changed, 1 insertion(+), 1 deletion(-)
git_push origin
tag my-gem 0.0.1
git_tag v0.0.1 v0.0.1
git_push origin
@taylorthurlow
Copy link

taylorthurlow commented Apr 2, 2019

I'm also experiencing the same issue. It also happens with the --release option as well - it builds and pushes the gem with the old version.

EDIT: I'm thinking maybe this is because I was using the --pretend flag. I haven't tried anything without it yet, but it might make sense that it doesn't update the version number.

@PikachuEXE
Copy link
Collaborator

Opened #83 to fix this issue > 50%
Why not 100%? Read the PR :)

@PikachuEXE
Copy link
Collaborator

If no rejection I will release #83 next week Friday

@PikachuEXE
Copy link
Collaborator

Partial fix released as 2.0.3

@bguest
Copy link

bguest commented May 12, 2021

I'm still experiencing this issue with version 2.2.1 gem bump patch, gem bump minor and gem bump patch all do the same thing, bump the patch version: ie:

$ gem bump major                                                                                                                                                                                                                                                                                                                                                                           rbenv:2.6.2

Bumping my_gem from version 1.1.3 to 1.1.4
Changing version in lib/my_gem/version.rb from 1.1.3 to 1.1.4

All is good, thanks my friend.

@PikachuEXE
Copy link
Collaborator

@bguest
I have reproduced your issue
Let me see why it works in spec...

@PikachuEXE
Copy link
Collaborator

@bguest
Oh you need to use --version like

gem bump --version major
gem bump --version minor

See gem bump doc

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

No branches or pull requests

4 participants