Skip to content

Instantly share code, notes, and snippets.

@sourcerebels
Created January 30, 2012 06:34
Show Gist options
  • Save sourcerebels/1702920 to your computer and use it in GitHub Desktop.
Save sourcerebels/1702920 to your computer and use it in GitHub Desktop.
Create Jasmine - Maven project
#
# Original documentation (http://searls.github.com/jasmine-maven-plugin/)
# Requires Maven (http://maven.apache.org)
#
ARTIFACT_ID=$1
GROUP_ID=$2
VERSION=$3
function usage() {
echo "usage $(basename $0) artifact [group] [version]"
exit 1
}
if [ -z "$ARTIFACT_ID" ]; then
echo "No artifact specified"
usage
fi
if [ -z "$GROUP_ID" ]; then
GROUP_ID=$ARTIFACT_ID
fi
if [ -z "$VERSION" ]; then
VERSION="0.0.1-SNAPSHOT"
fi
mvn archetype:generate \
-DarchetypeRepository=http://searls-maven-repository.googlecode.com/svn/trunk/snapshots \
-DarchetypeGroupId=com.github.searls \
-DarchetypeArtifactId=jasmine-archetype \
-DarchetypeVersion=1.1.0.1-SNAPSHOT \
-DgroupId=$GROUP_ID \
-DartifactId=$ARTIFACT_ID \
-Dversion=$VERSION
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment