Tag comparison doesn't work on the same branch
Zendesk ticket (internal link): https://gitlab.zendesk.com/agent/tickets/89515
A customer would like to be able to compare a tag with the latest changes on a given branch. At the moment, this isn't possible.
Reproduction steps
# Clone an empty project
git clone <url>
# Create a file, commit it to the master branch, and push it
echo 'This is a new project.' > README.md
git add README.md
git commit -m 'first commit'
git push
# Create a tag and push it
git tag -a v0.1 -m 'first tag'
git push --tags
# Make a change and commit it
echo "A new commit placed AFTER the tag was created." >> README.md
git commit -am 'second commit, after tag creation'
git push
Then go to the project's Repository -> Compare page, choose v0.1
as the Source and master
as the Target, and press Compare. Since there's only one branch, you will be given a message such as the below:
Locally, I'm able to get a diff when I run git diff <tag>...<latest_SHA>
. The customer is running 10.3.4-ee and I tried this on GitLab.com with 10.5.0-rc3-ee.
Example: https://gitlab.com/harish_test_group/tags-and-comparisons/compare/master...v0.1
What do you think about allowing for these types of comparisons?
Edited by Harish Ramachandran