git fsck
SafeCheck repo integrity
git fsck --lost-found
Detects corruption and dangling commits; --lost-found materializes recovery candidates.
Examples
git fsck --lost-foundSurface recoverable objects
Syntax
git fsck [--lost-found] [--full]
Before you run it
Inspection only.
Used when you see
Broke history with reset/rebase
3
See the whole flow →If reflog lacks it, hunt dangling commits with fsck
Related commands
- git reflogHEAD history (lifesaver)
- git gcGarbage collection
The same reference, with no signal at all
Every command and flow from this site, held on your device and searchable with no connection. Free to install, no ads.
Get it free on the App Store