AI engineering glossary · Command line Git
What is reflog?
Reflog: A local log of where HEAD and branch tips have pointed recently, including moves caused by resets and rebases. It is the safety net for recovering commits that seem lost.
Reflog: an example
After a bad hard reset, git reflog lists earlier positions, and git reset --hard HEAD@{2} restores one.
Related terms
More Command line Git terms
Where you learn it
Reflog is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.