Show only the 5 latest entries in the reflog

git reflog

  • Show a log of changes to local references like HEAD, branches or tags.
    More information: <https://git-scm.com/docs/git-reflog>.
  • Trick copyright: tl;dr; <https://github.com/tldr-pages/tldr>

git reflog -n {{5}}

click the source code to copy install git reflog on any operating system with command-not-found.com