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

Git version calculating wrong version when building a tag #2413

Merged
merged 10 commits into from
Nov 7, 2020
Merged

Git version calculating wrong version when building a tag #2413

merged 10 commits into from
Nov 7, 2020

Conversation

gerwinjansen
Copy link
Contributor

@gerwinjansen gerwinjansen commented Sep 30, 2020

Note: this PR is on top of #2411, that's why you see the changes again.

Description

TaggedCommitVersionStrategy will try to return the tags on the current commit. If there are none, it will returns the tags from the history.

Related Issue

Fixes #2074 GitVersion calculating wrong version when building a tag

How Has This Been Tested?

See steps to reproduce in my comments of the related ticket.

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@asbjornu
Copy link
Member

asbjornu commented Oct 4, 2020

This is great! But there's something odd going on with the Docker tests. Can you please look into that?

========================================
Docker-Test
========================================
Executing task: Docker-Test
Testing image: gittools/gitversion:5.4.0-linux-alpine.3.10-x64-netcoreapp2.1
Output : 5.4.0-PullRequest2413.140
An error occurred when executing task 'Docker-Test'.

----------------------------------------
Teardown
----------------------------------------
Executing custom teardown action...
Starting Teardown...
Repository info : IsMainRepo True, IsMainBranch False, IsTagged: False, IsPullRequest: True
Finished running tasks.
Error: One or more errors occurred. (Assert.Equal() Failure
                                 ↓ (pos 23)
Expected: ···.0-PullRequest2413.171
Actual:   ···.0-PullRequest2413.140
                                 ↑ (pos 23))
	Assert.Equal() Failure
                                 ↓ (pos 23)
Expected: ···.0-PullRequest2413.171
Actual:   ···.0-PullRequest2413.140
                                 ↑ (pos 23)
Error: Process completed with exit code 1.

@gerwinjansen
Copy link
Contributor Author

I have no clue how to run the docker tests locally and debug them.
Can you help me out?

@asbjornu
Copy link
Member

asbjornu commented Oct 8, 2020

Can you provide some guidance, @arturcic?

@asbjornu asbjornu mentioned this pull request Oct 13, 2020
5 tasks
@asbjornu
Copy link
Member

Can you please rebase on the HEAD of master and resolve conflicts, @gerwinjansen?

@gerwinjansen
Copy link
Contributor Author

@asbjornu: build is succesful (without any changes from my side). Can this PR be completed now?

@asbjornu asbjornu merged commit 9b55d9f into GitTools:master Nov 7, 2020
@asbjornu
Copy link
Member

asbjornu commented Nov 7, 2020

Excellent, thank you so much for your contribution @gerwinjansen! 🙏

@gerwinjansen gerwinjansen deleted the GitVersion-calculating-wrong-version-when-building-a-tag branch November 9, 2020 08:57
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.

[BUG] GitVersion calculating wrong version when building a tag
3 participants