Skip to content

Instantly share code, notes, and snippets.

@sqren sqren/clean-repos.sh
Last active Aug 29, 2015

Embed
What would you like to do?
Tradeshift: Update all repos, fix pom and clean
# Run the following in the folder containing all ts repos.
# Git pull
for dir in */; do
cd $dir
echo "Opening ${dir} and git pull"
git pull
cd ..
done
# Directories to clean
directories="App-Service
Backend-Service
Backend-Common
Frontend
App-Common
Integration-Test"
for dir in $directories
do
cd $dir
echo "Opening ${dir}"
if [ -f ./setup-pom.sh ];
then
./setup-pom.sh
fi
# Is Frontend (Grails)
if [ "$dir" == "Frontend/" ]
then
grails clean
grails maven-install
# Assume it is Maven
else
rm -rf target/
mvn clean install -DskipTests
fi
cd ..
done
echo "Finished!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.