-
Notifications
You must be signed in to change notification settings - Fork 34
/
release.sh
executable file
·33 lines (27 loc) · 1.04 KB
/
release.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/sh
echo ""
echo "######################################"
echo " Releasing Artificer"
echo "######################################"
echo ""
read -p "Release version: " RELEASE_VERSION
read -p "New development version: " DEV_VERSION
read -p "Full path to your private key: " KEYFILE
BRANCH=`git rev-parse --abbrev-ref HEAD`
echo ""
mvn versions:set -DnewVersion=$RELEASE_VERSION
find . -name '*.versionsBackup' -exec rm -f {} \;
# sanity check
mvn clean install -Pgenerate-docs
git add .
git commit -m "Prepare for release $RELEASE_VERSION"
git push origin $BRANCH
git tag -a -m "Tagging release $RELEASE_VERSION" artificer-$RELEASE_VERSION
git push origin artificer-$RELEASE_VERSION
mvn deploy -Pgenerate-docs,upload-docs -Dkeyfile=$KEYFILE
scp distro/assembly/target/artificer-$RELEASE_VERSION.zip [email protected]:/downloads_htdocs/artificer
mvn versions:set -DnewVersion=$DEV_VERSION
find . -name '*.versionsBackup' -exec rm -f {} \;
git add .
git commit -m "Update to next development version: $DEV_VERSION"
git push origin $BRANCH