If I do 'git describe' in my directory I get the output: 1.0-24-g31cdd0f
How does one do a checkout at this same point in the revision tree after it is no longer HEAD? How does one see the log for the 24 commits since the tag?
Looking up changes for a specific commit If you have the hash for a commit, you can use the git show command to display the changes for that single commit. The output is identical to each individual commit when using git log -p .
To reference a commit, simply write its SHA-hash, and it'll automatically get turned into a link.
4 : to pledge to do some particular thing When asked if he would volunteer, he wouldn't commit himself.
I disagree with the second part of the answer provided by Greg Hewgill.
Output : 1.0-24-g31cdd0f means that "1.0" is the latest reachable tag and it is 24 commits away from the recent commit "31cdd0f". So, doing git log 31cdd0f.. will not print anything. Because "31cdd0f" is the recent commit and leaving empty after ".." shows all commits till the recent commit.
The correct command should be
git log 1.0..31cdd0f
. This will show all commits between the tag "1.0" and recent commit "31cdd0f".
Sources:
https://schacon.github.io/git/git-describe.html
https://schacon.github.io/git/git-log.html
The commit that is tagged is the last part without the "g", so 31cdd0f
. You can checkout with:
git checkout 31cdd0f
or view the log of commits since the tag 1.0
with
git log 1.0..31cdd0f
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With