Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I use

    #!/bin/sh
    
    git checkout main
    git fetch --prune
    git branch | grep -v main | xargs --no-run-if-empty git branch -D
    git pull
Save that next to your git binary, call it whatever you want. It's destructive on purpose.
 help



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: