Skip to content

Instantly share code, notes, and snippets.

@harshbaid
Created May 1, 2023 21:28
Show Gist options
  • Select an option

  • Save harshbaid/3d704d81195bba2f8335c8f353d95b93 to your computer and use it in GitHub Desktop.

Select an option

Save harshbaid/3d704d81195bba2f8335c8f353d95b93 to your computer and use it in GitHub Desktop.
Cleans up disk space taken by .git folder.
git remote prune origin && git repack && git prune-packed && git reflog expire --expire=1.month.ago && git gc --aggressive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment