Git prune remote and local branches


/ Published in: Bash
Save to your folder(s)

http://yuji.wordpress.com/2010/06/11/git-delete-remote-branch/


Copy this code and paste it in your HTML
  1. # see what's out there
  2. git remote show origin
  3.  
  4. # remove the remote branch 'branch-name'
  5. git push origin :branch-name
  6.  
  7. # see what branches are only on local and no longer tracked
  8. git remote prune origin --dry-run
  9.  
  10. # run again without --dry-run to actually prune the local branch

URL: http://kparal.wordpress.com/2011/04/15/git-tip-of-the-day-pruning-stale-remote-tracking-branches/

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.