Browse Source

feat(etl): improve MD5 hash extraction

Updates the MD5 hash parsing to use a specific regex for 32-character hexadecimal strings, providing a more robust extraction from the release body than relying on the last field of the line.
pull/4896/head
Daniel Gibbs 2 months ago
parent
commit
a2ccce4234
Failed to extract signature
  1. 2
      lgsm/modules/update_etl.sh

2
lgsm/modules/update_etl.sh

@ -44,7 +44,7 @@ fn_update_remotebuild() {
remotebuildfilename=$(echo "${remotebuildresponse}" | jq -r '.assets[] | select(.browser_download_url | contains("i386-et-260b")) | .name')
remotebuildurl=$(echo "${remotebuildresponse}" | jq -r '.assets[] | select(.browser_download_url | contains("i386-et-260b")) | .browser_download_url')
remotebuild=$(echo "${remotebuildresponse}" | jq -r '.tag_name')
remotebuildhash=$(echo "${remotebuildresponse}" | jq -r '.body' | grep 'MD5' | awk '{print $NF}')
remotebuildhash=$(echo "${remotebuildresponse}" | jq -r '.body' | grep 'MD5' | grep -oE '[a-f0-9]{32}')
if [ "${firstcommandname}" != "INSTALL" ]; then
fn_print_dots "Checking remote build: ${remotelocation}"

Loading…
Cancel
Save