You can use “find” for remove all files in the /objects
directory with 0 in size with the command:
find .git/objects/ -size 0 -delete
Backup is recommended.
More Related Contents:
- Can “git pull” automatically stash and pop pending changes?
- Merge, update, and pull Git branches without using checkouts
- Where do the settings in my Git configuration come from?
- How to compare a local Git branch with its remote branch
- Change first commit of project with Git? [duplicate]
- What’s the equivalent of Subversion’s “use-commit-times” for Git?
- Checking out old files WITH original create/modified timestamps
- Warning: push.default is unset; its implicit value is changing in Git 2.0
- What exactly does the “u” do? “git push -u origin master” vs “git push origin master”
- configure Git to accept a particular self-signed server certificate for a particular https remote
- Is it possible to include a file in your .gitconfig
- How do I programmatically determine if there are uncommitted changes?
- How to inject a commit between some two arbitrary commits in the past?
- git difftool, open all diff files immediately, not in serial
- Git – remote: Repository not found
- Can I make a user-specific gitignore file?
- How to identify conflicting commits by hash during git rebase?
- How to git reset –hard a subdirectory
- Git-flow and master with multiple parallel release-branches
- error: Your local changes to the following files would be overwritten by checkout
- Git: How can I find a commit that most closely matches a directory?
- git push via cron
- What is the .git folder?
- Where does Git store the SHA1 of the commit for a submodule?
- How can I visualize per-character differences in a unified diff file?
- GitHub – HTTPS access
- git: push a single commit
- How to lookup the latest git commit hash from an ant build script
- Git and working on multiple branches
- git: command not found (on OS X 10.5)