You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by GitBox <gi...@apache.org> on 2020/10/07 17:12:54 UTC

[GitHub] [accumulo] ctubbsii commented on a change in pull request #1724: Update release candidate script

ctubbsii commented on a change in pull request #1724:
URL: https://github.com/apache/accumulo/pull/1724#discussion_r501177364



##########
File path: assemble/build.sh
##########
@@ -72,8 +74,43 @@ gitCommits() { pretty %H "$@"; }
 gitCommit()  { gitCommits -n1 "$@"; }
 gitSubject() { pretty %s "$@"; }
 
+selectFingerprint() {
+  local f fingerprints=()
+  if [[ $SELECTED_FINGERPRINT =~ ^[0-9a-fA-F]{40}$ ]]; then
+    # it's already set, don't set it again
+    return 0
+  fi
+  mapfile -t fingerprints < <(gpg --list-secret-keys --with-colons --with-fingerprint 2>/dev/null | awk -F: '$1 == "fpr" {print $10}')
+  fingerprints+=('Other')
+  echo
+  echo "Select the $(green gpg) key to use:"
+  COLUMNS=1
+  select f in "${fingerprints[@]}"; do
+    if [[ -z $f ]]; then
+      return 1
+    elif [[ $f == 'Other' ]]; then
+      SELECTED_FINGERPRINT=$(prompter "$(green gpg) key's $(green fingerprint)" '[0-9a-fA-F]{40}')
+      return 0
+    else
+      SELECTED_FINGERPRINT="$f"
+      return 0
+    fi
+  done
+}
+

Review comment:
       Yeah, it helps me, too, because I have several subkeys, and before this change, it was putting all three in the email and I had to delete the extras. Now, I just have to pick the correct one. :)




----------------------------------------------------------------
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:
users@infra.apache.org