Skip to content

Instantly share code, notes, and snippets.

@mushinlogit
Created June 14, 2018 14:58
Show Gist options
  • Save mushinlogit/0e34137c99e45a716f049c9688e2e47c to your computer and use it in GitHub Desktop.
Save mushinlogit/0e34137c99e45a716f049c9688e2e47c to your computer and use it in GitHub Desktop.
git-up.sh
#!/bin/bash
function gitClean() {
echo "prune local branches"
git branch -avv | grep gone | cut -d '\'' '\'' -f 3 | xargs git branch -D';
}
for PROJ in "unfetter-store" "unfetter" "unfetter-ui" "taxii-server" "stix" "stix2pattern"
do
pushd $PROJ
git up
git pull
gitClean
popd
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment