Created
January 14, 2017 19:28
-
-
Save ubaldop/a75601ba8e40a6581139a5e97b09c3c2 to your computer and use it in GitHub Desktop.
Script to build and run Freedomotic with a specific plugin
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
#!/bin/bash | |
if [[ $# -le 1 ]] ; then | |
echo 'No plugins parameters provided. Please run the script with a plugin type and name. (e.g.: devices persistence)' | |
exit 0 | |
fi | |
freedomoticHome=$(pwd) | |
echo "Building freedomotic..." | |
mvn clean install | |
echo "Building plugin"$1"/"$2" and skipping integration tests, if any." | |
cd $freedomoticHome/plugins/$1/$2 | |
mvn clean install -DskipITs | |
echo "Plugin built!" | |
cd $freedomoticHome | |
echo | |
echo "Moving built plugin from IDE to freedomotic environment..." | |
rm -R $freedomoticHome/framework/freedomotic-core/plugins/$1/$2 | |
mv $freedomoticHome/plugins/$1/$2/target/$2 $freedomoticHome/framework/freedomotic-core/plugins/$1 | |
echo "Built plugin moved properly" | |
echo "Launch Freedomotic!" | |
java -jar $freedomoticHome/framework/freedomotic-core/target/freedomotic-core/freedomotic.jar |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment