-
Notifications
You must be signed in to change notification settings - Fork 2
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
Version strings generated in github actions workflows are incorrect #21
Comments
Tried locally (on the machine where I actually did the tag).
When I |
Hmm, from https://stackoverflow.com/questions/66913267/wrong-commit-hash-with-git-rev-parse-tag it seems that the SHA returned by So now the question is: if the github action does the checkout by commit SHA, why does |
There is a workaround: if I use |
The github actions checkout workflow makes
git describe
misbehave. Specifically, when I am at tagv7.3.5
, with sha4db202a
then thegit describe
output isv7.3.4-1-g4db202a
. That is also a correct description, butv7.3.5
is really the correct one.This is probably due to actions/checkout#272 (which is also referenced by various other projects that are running into this issue).
Running
git log
doesn't show anything wrong. Tried with checkout v3 and v2.fetch-depth
has been set to0
.There is one funny thing in the
actions/checkout
output: there is a call of/usr/bin/git rev-parse refs/tags/v7.3.5
which produces the SHA46bee472f441d8030bd6e485f077e53f1dc26440
, which is not the same as4db202ad3831b9a33aa86f347ddd84f5ba17d754
. The latter is the SHA as it is in the origin repo (and in local checkouts).Need to investigate more, possibly by locally repeating everything github checkout action does.
The text was updated successfully, but these errors were encountered: