metron-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jonzeo...@apache.org
Subject metron git commit: METRON-1821 Align prepare-release-candidate with documentation (JonZeolla via jonzeolla) closes apache/metron#1236
Date Mon, 15 Oct 2018 13:43:13 GMT
Repository: metron
Updated Branches:
  refs/heads/master 90c5e1d28 -> 647896604


METRON-1821 Align prepare-release-candidate with documentation (JonZeolla via jonzeolla) closes
apache/metron#1236


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

Branch: refs/heads/master
Commit: 647896604f938ca195bf25885651f9be3e897c71
Parents: 90c5e1d
Author: JonZeolla <zeolla@gmail.com>
Authored: Mon Oct 15 09:42:44 2018 -0400
Committer: jonzeolla <jonzeolla@apache.org>
Committed: Mon Oct 15 09:42:44 2018 -0400

----------------------------------------------------------------------
 .../release-utils/prepare-release-candidate     | 23 +++++++++-----------
 1 file changed, 10 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/metron/blob/64789660/dev-utilities/release-utils/prepare-release-candidate
----------------------------------------------------------------------
diff --git a/dev-utilities/release-utils/prepare-release-candidate b/dev-utilities/release-utils/prepare-release-candidate
index bedee9b..635285c 100755
--- a/dev-utilities/release-utils/prepare-release-candidate
+++ b/dev-utilities/release-utils/prepare-release-candidate
@@ -33,9 +33,10 @@ BRO_PLUGIN_UPSTREAM="https://git-wip-us.apache.org/repos/asf/${BRO_PLUGIN_REPO_N
 
 DEV_REPO="https://dist.apache.org/repos/dist/dev/metron"
 RELEASE_REPO=" https://dist.apache.org/repos/dist/release/metron"
-PLUGIN_GIT_REPO="https://git-wip-us.apache.org/repos/asf/metron-bro-plugin-kafka.git"
+PLUGIN_GIT_REPO="https://git-wip-us.apache.org/repos/asf/${BRO_PLUGIN_REPO_NAME}.git"
 
 RC_PREFIX=rc
+UPPER_RC_PREFIX="$(tr '[:lower:]' '[:upper:]' <<< ${RC_PREFIX})"
 TAG_POSTFIX="-release"
 
 CONFIG_FILE=~/.metron-prepare-release-candidate
@@ -223,33 +224,29 @@ if [ "${PRACTICE_RUN}" = true ]; then
   printf "This is a practice run. Not running <git push --set-upstream origin %s_%s>\n"
"${CAPITAL_REPO}" "$VERSION"
 else
   printf "Pushing branch %s_%s\n" "${CAPITAL_REPO}" "$VERSION"
-  git push --set-upstream origin "${BRANCH_PREFIX}_${BRANCH_VERSION}"
+  git push --set-upstream origin "${CAPITAL_REPO}_${VERSION}"
 fi
 
 # Create directory for release artifacts
 if [ "${CHOSEN_REPO}" = "${METRON_REPO_NAME}" ]; then
-  ART_DIR="$WORKDIR/dev/metron/${VERSION}-RC${RC_NUM}"
+  ART_DIR="$WORKDIR/dev/metron/${VERSION}-${UPPER_RC_PREFIX}${RC_NUM}"
 else
   # We're using a sub module, so put it in it's own directory.
-  ART_DIR="$WORKDIR/dev/metron/${CHOSEN_REPO}/${VERSION}-RC${RC_NUM}"
+  ART_DIR="$WORKDIR/dev/metron/${CHOSEN_REPO}/${VERSION}-${UPPER_RC_PREFIX}${RC_NUM}"
 fi
 mkdir -p "$ART_DIR"
 
 # Setup various parameters we need for the release artifacts
 if [ "${CHOSEN_REPO}" = "${METRON_REPO_NAME}" ]; then
-  CORE_PREFIX="apache-metron-"
+  CORE_PREFIX="apache-metron_"
   ARTIFACT_PREFIX="${CORE_PREFIX}"
   TAG_VERSION="${CURRENT_VERSION}"
   TAG="${CORE_PREFIX}${TAG_VERSION}${TAG_POSTFIX}"
 elif [ "${CHOSEN_REPO}" = "${BRO_PLUGIN_REPO_NAME}" ]; then
-  PLUGIN_PREFIX="apache-metron-bro-plugin-kafka_"
-  ARTIFACT_PREFIX="${PLUGIN_PREFIX}"
+  BRO_PLUGIN_PREFIX="apache-metron-bro-plugin-kafka_"
+  ARTIFACT_PREFIX="${BRO_PLUGIN_PREFIX}"
   TAG_VERSION="${CURRENT_VERSION}"
-  TAG="${PLUGIN_PREFIX}${TAG_VERSION}${TAG_POSTFIX}"
-  # Handle special tag case from prior release
-  if [ "${TAG_VERSION}" = "0.1" ]; then
-    TAG="0.1"
-  fi
+  TAG="${BRO_PLUGIN_PREFIX}${TAG_VERSION}${TAG_POSTFIX}"
 else
   # If we ever add new modules, add them as needed.
   printf "Unrecognized module: %s\n" "${CHOSEN_REPO}"
@@ -324,7 +321,7 @@ if [ "${PRACTICE_RUN}" = true ]; then
   printf "<svn add %s>\n" ${COMMIT_DIR}
   printf "<svn commit -m \"Adding artifacts for %s %s\">\n" "${CHOSEN_REPO}" "${COMMIT_DIR}"
 else
-  printf "Adding artifacts for Metron ${VERSION}-RC${RC_NUM} to dev SVN\n"
+  printf "Adding artifacts for Metron ${VERSION}-${UPPER_RC_PREFIX}${RC_NUM} to dev SVN\n"
   # Metron goes in the root of the dir, submodules go in folder
   if [ "${CHOSEN_REPO}" = "${METRON_REPO_NAME}" ]; then
     cd "$WORKDIR/dev/metron/"


Mime
View raw message