petersomogyi commented on a change in pull request #671: HBASE-23092 Make the 
RM tooling in dev-tools/create-release generic
URL: https://github.com/apache/hbase/pull/671#discussion_r329961209
 
 

 ##########
 File path: dev-support/create-release/release-util.sh
 ##########
 @@ -269,43 +275,115 @@ function init_mvn {
 
 # Writes report into cwd!
 function generate_api_report {
-  local hbase=$1
+  local project="$1"
   local previous_tag="$2"
   local release_tag="$3"
   # Generate api report.
-  ${hbase}/dev-support/checkcompatibility.py --annotation \
+  ${project}/dev-support/checkcompatibility.py --annotation \
     org.apache.yetus.audience.InterfaceAudience.Public  \
     $previous_tag $release_tag
   local previous_version=$(echo ${previous_tag} | sed -e 's/rel\///')
-  cp ${hbase}/target/compat-check/report.html 
"./api_compare_${previous_version}_to_${release_tag}.html"
+  cp ${project}/target/compat-check/report.html 
"./api_compare_${previous_version}_to_${release_tag}.html"
 }
 
 # Update the CHANGES.md
 # DOES NOT DO COMMITS! Caller should do that.
 # yetus requires python2 to be on the path.
 function update_releasenotes {
-  local hbase="$1"
+  local project="$1"
   local release_version="$2"
   local yetus="apache-yetus-${YETUS_VERSION}"
   wget -qO- 
"https://www.apache.org/dyn/mirrors/mirrors.cgi?action=download&filename=/yetus/${YETUS_VERSION}/${yetus}-bin.tar.gz";
 | \
     tar xvz -C .
-  cd ./${yetus}
+  cd ./${yetus} || exit
   ./bin/releasedocmaker -p HBASE --fileversions -v ${release_version} -l 
--sortorder=newer --skip-credits
   # First clear out the changes written by previous RCs.
   sed -i -e "/^## Release ${release_version}/,/^## Release/ {//!d; /^## 
Release ${release_version}/d;}" \
-    ${hbase}/CHANGES.md
-  sed -i -e "/^# HBASE  ${release_version} Release Notes/,/^# HBASE/{//!d; /^# 
HBASE  ${release_version} Release Notes/d;}" \
-    ${hbase}/RELEASENOTES.md
+    ${project}/CHANGES.md || true
+  sed -i -e "/^# ${project} ${release_version} Release Notes/,/^# 
${project}/{//!d; /^# ${project} ${release_version} Release Notes/d;}" \
 
 Review comment:
   This does not work like this. Check 
[#35](https://github.com/apache/hbase-operator-tools/pull/35).
   Rerunning an RC will duplicate the release notes. This happened with the 
latest hbase-thirdparty 3.1.0RC1.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to