Skip to content

Commit

Permalink
scripts: Add 'deploy' script
Browse files Browse the repository at this point in the history
Signed-off-by: Jussi Virtanen <jussi.virtanen@valotrading.com>
  • Loading branch information
Jussi Virtanen committed Apr 15, 2014
1 parent 8a2b4a7 commit 1acd620
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions scripts/deploy
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/sh

set -e

if [ $# -ne 2 ]; then
echo "Usage: `basename $0` <version> <deployment-repository>"
exit 2
fi

if [ -n "$(git status --porcelain)" ]; then
echo "Your repository contains local changes or unversioned files. Aborting." >&2
exit 1
fi

version=$1
deployment_repository=$2

git checkout "v$version"

mvn deploy -DaltDeploymentRepository=mine::default::file://$deployment_repository

git checkout -

0 comments on commit 1acd620

Please sign in to comment.