Our host lets us deploy using git push, to any branch. It looks like a few extra branches have been pushed to the host by mistake. Before I remove all the extra branches, I would like to double check which branch contains the current state of our live code, ie which branch remote head is currently at.
I've tried git branch -rv --list
, but that just lists remote branches without showing head. I tried git log production --all --decorate --oneline
, but that is showing me the local "production" branch, not all branches on the "production" remote.
You can try:
git checkout production
git branch -r --contains HEAD
In order to list all remote branches referencing HEAD .
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.