Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
git_gc [2019/03/02 08:37] – [Examples] rpjdaygit_gc [2019/03/07 09:46] (current) – [Examples] rpjday
Line 2: Line 2:
  
 How to clean up dangling and unreachable objects. How to clean up dangling and unreachable objects.
 +
 +Links:
 +
 +  * [[https://stackoverflow.com/questions/3765234/listing-and-deleting-git-commits-that-are-under-no-branch-dangling/4528593#4528593|Stack Overflow posting]]
  
 ===== SYNOPSIS ===== ===== SYNOPSIS =====
Line 96: Line 100:
 dangling commit 69fd5e6a8733ed63293aab658d584150c0af9db2 dangling commit 69fd5e6a8733ed63293aab658d584150c0af9db2
 $ $
 +</code>
  
 Prune now: Prune now:
Line 109: Line 114:
 $ $
 </code> </code>
- All gone:+ 
 +All gone:
  
 <code> <code>
Line 116: Line 122:
 Checking objects: 100% (11352/11352), done. Checking objects: 100% (11352/11352), done.
 $ $
 +</code>
 +
 +Clearing the reflog first:
 +
 +<code>
 +$ git reflog expire --expire=now --expire-unreachable=now --all
 +$ git gc --prune=now
 </code> </code>
  • git_gc.1551515841.txt.gz
  • Last modified: 2019/03/02 08:37
  • by rpjday