Last active
August 29, 2015 13:57
-
-
Save sorenlouv/9493679 to your computer and use it in GitHub Desktop.
Tradeshift: Update all repos, fix pom and clean
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 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