You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@systemds.apache.org by ar...@apache.org on 2020/09/21 17:59:54 UTC
[systemds] branch master updated: [SYSTEMDS-2667] Minor fixes in
the release scripts
This is an automated email from the ASF dual-hosted git repository.
arnabp20 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/systemds.git
The following commit(s) were added to refs/heads/master by this push:
new caa2881 [SYSTEMDS-2667] Minor fixes in the release scripts
caa2881 is described below
commit caa28818b425b2489d1d4e1abdfdeb05eceb89fd
Author: arnabp <ar...@tugraz.at>
AuthorDate: Mon Sep 21 19:58:07 2020 +0200
[SYSTEMDS-2667] Minor fixes in the release scripts
---
dev/release/{svn_dev_upload.sh => deploy.sh} | 64 +++++++++++++++++-----------
dev/release/old-release-build.sh | 7 +--
dev/release/svn_dev_upload.sh | 4 +-
3 files changed, 44 insertions(+), 31 deletions(-)
diff --git a/dev/release/svn_dev_upload.sh b/dev/release/deploy.sh
similarity index 50%
copy from dev/release/svn_dev_upload.sh
copy to dev/release/deploy.sh
index 8c850ea..9d9d842 100644
--- a/dev/release/svn_dev_upload.sh
+++ b/dev/release/deploy.sh
@@ -23,42 +23,54 @@
MVN=mvn
PUBLISH_PROFILES="-Pdistribution,rat"
DRY_RUN=-DdryRun=true
-GPG_PASSPHRASE=$1
-DEVELOPMENT_VERSION=2.0-SNAPSHOT
-RELEASE_TAG=v2.0
+GPG_KEYID=$1
+GPG_PASSPHRASE=$2
+DEVELOPMENT_VERSION=2.1.0-SNAPSHOT
RELEASE_STAGING_LOCATION="/c/virtual\ D/SystemDS/systemds/temp"
BASE_DIR="/c/virtual\ D/SystemDS/systemds"
-RELEASE_WORK_DIR="/c/virtual\ D/SystemDS/systemds/target/release2"
-RELEASE_VERSION=2.0
+#BASE_DIR="../.." #points to systemds directory
+RELEASE_WORK_DIR=$BASE_DIR/target/release2
+RELEASE_VERSION=2.0.0
RELEASE_RC=rc1
GIT_REF=-master
#export GNUPGHOME="/c/virtual\ D/SystemDS/systemds/target/.gnupg_copy"
export GNUPGHOME="../../../target/.gnupg_copy/"
-RELEASE_STAGING_REMOTE="https://dist.apache.org/repos/dist/dev/systemds/"
-eval cd $RELEASE_STAGING_LOCATION;
-rm -rf svn-release-staging
-# Checkout the artifacts
-svn co $RELEASE_STAGING_REMOTE svn-release-staging
-rm -rf svn-release-staging/$RELEASE_VERSION-$RELEASE_RC
-# Create a new folder for this release
-mkdir -p svn-release-staging/$RELEASE_VERSION-$RELEASE_RC
-# Copy the artifacts from target
-eval cp $RELEASE_WORK_DIR/systemds/target/systemds-*-bin.* svn-release-staging/$RELEASE_VERSION-$RELEASE_RC/
-eval cp $RELEASE_WORK_DIR/systemds/target/systemds-*-src.* svn-release-staging/$RELEASE_VERSION-$RELEASE_RC/
+function checkout_code {
+ # Checkout code
+ eval rm -rf $RELEASE_WORK_DIR
+ eval mkdir -p $RELEASE_WORK_DIR
+ eval cd $RELEASE_WORK_DIR
+ git clone https://github.com/apache/systemds.git
+ cd systemds
+ git checkout $GIT_REF
+ git_hash=`git rev-parse --short HEAD`
+ echo "Checked out SystemDS git hash $git_hash"
-cd svn-release-staging/$RELEASE_VERSION-$RELEASE_RC/
-rm -f *.asc
-for i in *.zip *.tgz; do gpg --output $i.asc --detach-sig --armor $i; done
-rm -f *.sha512
-for i in *.zip *.tgz; do shasum -a 512 $i > $i.sha512; done
+ git clean -d -f -x
+ #rm .gitignore
+ #rm -rf .git
-cd .. #exit $RELEASE_VERSION-$RELEASE_RC/
+ eval cd "$BASE_DIR" #return to base dir
+}
+
+# Pull the latest code (with committed pom changes) and deploy to the local target directory
+checkout_code
+# Remove SNAPSHOT from the version in pom
+eval cd $RELEASE_WORK_DIR/systemds
+sed -i "s/<version>$RELEASE_VERSION-SNAPSHOT<\/version>/<version>$RELEASE_VERSION<\/version>/" pom.xml
+GPG_OPTS="-Dgpg.keyname=$GPG_KEYID -Dgpg.passphrase=$GPG_PASSPHRASE"
+# Deploy to /target folder for the next job to pick the artifacts up for there
+CMD="$MVN $PUBLISH_PROFILES deploy \
+-DskiptTests \
+-DaltDeploymentRepository=altDepRepo::default::file:./target \
+${GPG_OPTS}"
+
+echo "Executing: " "$CMD"
+$CMD
+
+eval cd $RELEASE_WORK_DIR
-#svn add $RELEASE_VERSION-$RELEASE_RC/
-svn add $(svn status | awk '{$1=""; print $0}')
-#svn ci -m"Apache systemds $RELEASE_VERSION-$RELEASE_RC"
-#manually commit from tortoise
exit 0
diff --git a/dev/release/old-release-build.sh b/dev/release/old-release-build.sh
index b6ac12b..d3bb088 100644
--- a/dev/release/old-release-build.sh
+++ b/dev/release/old-release-build.sh
@@ -269,19 +269,20 @@ if [[ "$RELEASE_PREPARE" == "true" ]]; then
#sed -i .bak "s|<tag>HEAD<\/tag>|<tag>$RELEASE_TAG<\/tag>|" $BASE_DIR/target/release/systemds/pom.xml
# Remove SNAPSHOT from the version in pom
- sed -i "s/<version>$RELEASE_VERSION-SNAPSHOT<\/version>/<version>$RELEASE_VERSION<\/version>/" /c/virtual\ D/SystemDS/systemds/target/release2/systemds/pom.xml
eval cd $RELEASE_WORK_DIR/systemds
## Rerunning mvn with clean and package goals, as release:prepare changes ordeer for some dependencies like unpack and shade.
$MVN $PUBLISH_PROFILES clean package $DRY_RUN \
-Darguments="-Dgpg.passphrase=\"$GPG_PASSPHRASE\" \
-DskipTests" \
-DreleaseVersion="$RELEASE_VERSION" -DdevelopmentVersion="$DEVELOPMENT_VERSION" -Dtag="$RELEASE_TAG" \
-
+
+ exit
+
# Pull the latest code (with committed pom changes) and deploy to the local target directory
checkout_code
# Remove SNAPSHOT from the version in pom
- sed -i "s/<version>$RELEASE_VERSION-SNAPSHOT<\/version>/<version>$RELEASE_VERSION<\/version>/" /c/virtual\ D/SystemDS/systemds/target/release2/systemds/pom.xml
eval cd $RELEASE_WORK_DIR/systemds
+ sed -i "s/<version>$RELEASE_VERSION-SNAPSHOT<\/version>/<version>$RELEASE_VERSION<\/version>/" pom.xml
GPG_OPTS="-Dgpg.keyname=$GPG_KEYID -Dgpg.passphrase=$GPG_PASSPHRASE"
# Deploy to /target folder for the next job to pick the artifacts up for there
CMD="$MVN $PUBLISH_PROFILES deploy \
diff --git a/dev/release/svn_dev_upload.sh b/dev/release/svn_dev_upload.sh
index 8c850ea..6f3dc0f 100644
--- a/dev/release/svn_dev_upload.sh
+++ b/dev/release/svn_dev_upload.sh
@@ -24,12 +24,12 @@ MVN=mvn
PUBLISH_PROFILES="-Pdistribution,rat"
DRY_RUN=-DdryRun=true
GPG_PASSPHRASE=$1
-DEVELOPMENT_VERSION=2.0-SNAPSHOT
+DEVELOPMENT_VERSION=2.1.0-SNAPSHOT
RELEASE_TAG=v2.0
RELEASE_STAGING_LOCATION="/c/virtual\ D/SystemDS/systemds/temp"
BASE_DIR="/c/virtual\ D/SystemDS/systemds"
RELEASE_WORK_DIR="/c/virtual\ D/SystemDS/systemds/target/release2"
-RELEASE_VERSION=2.0
+RELEASE_VERSION=2.0.0
RELEASE_RC=rc1
GIT_REF=-master
#export GNUPGHOME="/c/virtual\ D/SystemDS/systemds/target/.gnupg_copy"