Locally, you can use git log . The git log command enables you to display a list of all of the commits on your current branch. By default, the git log command presents a lot of information all at once.
Command #1: git branch -r This Git command will show you remote branches. The -r flag here is short for --remotes . This is the command I use personally.
Try this -
git log --branches=*
The following should do what you want:
git rev-list --remotes
The documentation for the --remotes
option says:
--remotes[=<pattern>]
Pretend as if all the refs in refs/remotes are listed on the command line as <commit>. If <pattern> is given, limit remote-tracking branches to ones matching given shell glob. If pattern lacks ?, , or [, / at the end is implied.
As a point of pedantry, these are "remote-tracking branches" rather than "remote branches" - the latter is a somewhat ambiguous term in git, since you might be referring to a branch in remote repository or a remote-tracking branch (which is like a cache of the state of the branch in the remote repository).
Simple:
git rev-list --all --remotes
I hope that helps
Of course, drop the --all if you just want to list revisions in remotes (which 90% of the time will overlap those in your local branches)
If you want refrences with it use this--
git show-ref
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