When you use git filter-branch
, a backup file is created in
refs/original/refs/heads/master
If you used the command in branch master
. You can check if you have the backup in .git/refs
directory. With this in mind, you can use this backup to recover your files with:
git reset --hard refs/original/refs/heads/master
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…