You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flink.apache.org by ch...@apache.org on 2018/07/19 08:25:22 UTC

flink git commit: [FLINK-9748][release] Use dedicated directory for release artifacts

Repository: flink
Updated Branches:
  refs/heads/master c5b3d1731 -> 749dd2993


[FLINK-9748][release] Use dedicated directory for release artifacts

This closes #6342.


Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/749dd299
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/749dd299
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/749dd299

Branch: refs/heads/master
Commit: 749dd29935f319b062051141e150eed7a1a5f298
Parents: c5b3d17
Author: zentol <ch...@apache.org>
Authored: Mon Jul 16 15:16:19 2018 +0200
Committer: zentol <ch...@apache.org>
Committed: Thu Jul 19 10:25:15 2018 +0200

----------------------------------------------------------------------
 .gitignore                               |  1 +
 pom.xml                                  |  2 ++
 tools/releasing/create_binary_release.sh | 15 ++++++++++-----
 tools/releasing/create_source_release.sh | 21 +++++++++++++--------
 4 files changed, 26 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/749dd299/.gitignore
----------------------------------------------------------------------
diff --git a/.gitignore b/.gitignore
index 8fc9fce..1fde2d9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -34,3 +34,4 @@ out/
 *.iws
 tools/flink
 tools/flink-*
+tools/releasing/release

http://git-wip-us.apache.org/repos/asf/flink/blob/749dd299/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index ec6d6d6..6d251f1 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1150,6 +1150,8 @@ under the License.
 						<!-- Tools: watchdog -->
 						<exclude>tools/artifacts/**</exclude>
 						<exclude>tools/flink*/**</exclude>
+						<!-- artifacts created during release process -->
+						<exclude>tools/releasing/release/**</exclude>
 						<!-- manually installed version on travis -->
 						<exclude>apache-maven-3.2.5/**</exclude>
 						<!-- PyCharm -->

http://git-wip-us.apache.org/repos/asf/flink/blob/749dd299/tools/releasing/create_binary_release.sh
----------------------------------------------------------------------
diff --git a/tools/releasing/create_binary_release.sh b/tools/releasing/create_binary_release.sh
index 374c785..0bdff60 100755
--- a/tools/releasing/create_binary_release.sh
+++ b/tools/releasing/create_binary_release.sh
@@ -44,6 +44,12 @@ else
     SHASUM="sha512sum"
 fi
 
+cd ..
+
+FLINK_DIR=`pwd`
+RELEASE_DIR=${FLINK_DIR}/tools/releasing/release
+mkdir -p ${RELEASE_DIR}
+
 ###########################
 
 # build maven package, create Flink distribution, generate signature
@@ -65,18 +71,17 @@ make_binary_release() {
   cd flink-dist/target/flink-*-bin/
   tar czf "${dir_name}.tgz" flink-*
 
-  cp flink-*.tgz ../../../
-  cd ../../../
+  cp flink-*.tgz ${RELEASE_DIR}
+  cd ${RELEASE_DIR}
 
   # Sign sha the tgz
   if [ "$SKIP_GPG" == "false" ] ; then
     gpg --armor --detach-sig "${dir_name}.tgz"
   fi
   $SHASUM "${dir_name}.tgz" > "${dir_name}.tgz.sha512"
-}
-
-cd ..
 
+  cd ${FLINK_DIR}
+}
 
 if [ "$SCALA_VERSION" == "none" ] && [ "$HADOOP_VERSION" == "none" ]; then
   make_binary_release "" "-DwithoutHadoop" "2.11"

http://git-wip-us.apache.org/repos/asf/flink/blob/749dd299/tools/releasing/create_source_release.sh
----------------------------------------------------------------------
diff --git a/tools/releasing/create_source_release.sh b/tools/releasing/create_source_release.sh
index dca7281..0cc32fe 100755
--- a/tools/releasing/create_source_release.sh
+++ b/tools/releasing/create_source_release.sh
@@ -45,11 +45,17 @@ fi
 
 cd ..
 
+FLINK_DIR=`pwd`
+RELEASE_DIR=${FLINK_DIR}/tools/releasing/release
+CLONE_DIR=${RELEASE_DIR}/flink-tmp-clone
+
 echo "Creating source package"
 
+mkdir -p ${RELEASE_DIR}
+
 # create a temporary git clone to ensure that we have a pristine source release
-git clone . flink-tmp-clone
-cd flink-tmp-clone
+git clone ${FLINK_DIR} ${CLONE_DIR}
+cd ${CLONE_DIR}
 
 rsync -a \
   --exclude ".git" --exclude ".gitignore" --exclude ".gitattributes" --exclude ".travis.yml" \
@@ -58,10 +64,9 @@ rsync -a \
   --exclude "docs/content" --exclude ".rubydeps" \
   . flink-$RELEASE_VERSION
 
-tar czf flink-${RELEASE_VERSION}-src.tgz flink-$RELEASE_VERSION
-gpg --armor --detach-sig flink-$RELEASE_VERSION-src.tgz
-$SHASUM flink-$RELEASE_VERSION-src.tgz > flink-$RELEASE_VERSION-src.tgz.sha512
+tar czf ${RELEASE_DIR}/flink-${RELEASE_VERSION}-src.tgz flink-$RELEASE_VERSION
+gpg --armor --detach-sig ${RELEASE_DIR}/flink-$RELEASE_VERSION-src.tgz
+$SHASUM ${RELEASE_DIR}/flink-$RELEASE_VERSION-src.tgz > ${RELEASE_DIR}/flink-$RELEASE_VERSION-src.tgz.sha512
 
-mv flink-$RELEASE_VERSION-src.* ../
-cd ..
-rm -rf flink-tmp-clone
+cd ${CURR_DIR}
+rm -rf ${CLONE_DIR}