Add some more advanced tips

This commit is contained in:
Chalarangelo
2021-04-06 21:35:01 +03:00
parent 676a0aba80
commit cf58b9c285
5 changed files with 101 additions and 0 deletions

View File

@ -0,0 +1,20 @@
---
title: Find lost files
tags: repository,advanced
---
Prints a list of lost files and commits.
- Use `git fsck --lost-found` to print a list of all dangling objects.
- All appropriate files will be extracted into the `.git/lost-found` directory.
```sh
git fsck --lost-found
```
```sh
git fsck --lost-found
# dangling commit 3050fc0de
# dangling blob 807e3fa41
# dangling commit 59ff8481d
```