/tmp/test $ git init
Initialized empty Git repository in /tmp/test/.git/
/tmp/test master # $ git commit --allow-empty -m 'Commit #1'
[master (root-commit) 1dc2d41] Commit #1
/tmp/test master $ git co -b feature
Switched to a new branch 'feature'
/tmp/test feature $ git commit --allow-empty -m 'Commit #2'
[feature f35f72b] Commit #2
/tmp/test feature $ SHA=$(git rev-parse HEAD)
/tmp/test feature $ git co master
Switched to branch 'master'
/tmp/test master $ git show --pretty=oneline $SHA
f35f72b78586ca394dc9cccb33c7fab18d2aa373 Commit #2
sg302447 /tmp/test master $ git branch -D feature
Deleted branch feature (was f35f72b).
/tmp/test master $ git gc --aggressive
Enumerating objects: 3, done.
Counting objects: 100% (3/3), done.
Delta compression using up to 4 threads
Compressing objects: 100% (2/2), done.
Writing objects: 100% (3/3), done.
Total 3 (delta 1), reused 2 (delta 0)
/tmp/test master $ git show --pretty=oneline $SHA
f35f72b78586ca394dc9cccb33c7fab18d2aa373 Commit #2
Почему Commit #2
все еще существует?