How to get the ref/hash of tip of branch #926
Unanswered
manuel-koch
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I want the commit hash of a local/remote branch tip.
What would be an equivalent go-git code?
For a local branch:
git rev-list my-branch | head -1
or a remote branch:
git rev-list origin/my-branch | head -1
Beta Was this translation helpful? Give feedback.
All reactions