Clean Local Git Repository
Keeping your local repository clean is helpful to development work.
1. Clean Rubbish
$ git gc
$ git prune
 
2. Clean the branches that are no longer in the remote repository
$ git remote prune origin
 
3. Clean the tags that are no longer in the remote repository
$ git fetch origin --prune --prune-tags --force
 
or
$ git tag -d $(git tag)
$ git fetch --tags
 
Ref:
- Remove local git tags that are no longer on the remote repository
 










