Skip to content

Commit f1df5ad

Browse files
Include Changelogs URL for Nodes
Include Changelogs URL for Nodes
1 parent d6d88eb commit f1df5ad

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

MerlinAU.sh

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3060,6 +3060,7 @@ _GetNodeInfo_()
30603060
node_build_name="Unreachable"
30613061
node_lan_hostname="Unreachable"
30623062
node_label_mac="Unreachable"
3063+
NodeGNUtonFW=false
30633064

30643065
## Check for Login Credentials ##
30653066
credsBase64="$(Get_Custom_Setting credentials_base64)"
@@ -3122,6 +3123,9 @@ _GetNodeInfo_()
31223123
node_lan_hostname="$(echo "$htmlContent" | grep -o '"lan_hostname":"[^"]*' | sed 's/"lan_hostname":"//')"
31233124
node_label_mac="$(echo "$htmlContent" | grep -o '"label_mac":"[^"]*' | sed 's/"label_mac":"//')"
31243125

3126+
# Check if installed F/W NVRAM vars contain "gnuton" #
3127+
if echo "$node_extendno" | grep -iq "gnuton"
3128+
then NodeGNUtonFW=true ; fi
31253129
# Combine extracted information into one string #
31263130
Node_combinedVer="${node_firmver}.${node_buildno}.$node_extendno"
31273131

@@ -5992,6 +5996,23 @@ _CheckNodeFWUpdateNotification_()
59925996
echo ""
59935997
echo "AiMesh Node <b>${nodefriendlyname}</b> with MAC address <b>${node_label_mac}</b> requires update from <b>${1}</b> to <b>${2}</b> version."
59945998
echo "(<b>${1}</b> --> <b>${2}</b>)"
5999+
echo "Please click here to review the latest changelog:"
6000+
if "$NodeGNUtonFW"
6001+
then
6002+
Gnuton_changelogurl="$(GetLatestChangelogUrl "$FW_GITURL_RELEASE")"
6003+
echo "$Gnuton_changelogurl"
6004+
else
6005+
if [ "$node_firmver" -eq 3006 ]
6006+
then
6007+
changeLogURL="${CL_URL_3006}"
6008+
elif echo "$node_firmver" | grep -qE "^386[.]"
6009+
then
6010+
changeLogURL="${CL_URL_386}"
6011+
else
6012+
changeLogURL="${CL_URL_NG}"
6013+
fi
6014+
echo "$changeLogURL"
6015+
fi
59956016
echo "Automated update will be scheduled <b>only if</b> MerlinAU is installed on the node."
59966017
} > "$tempNodeEMailList"
59976018
fi
@@ -6007,6 +6028,23 @@ _CheckNodeFWUpdateNotification_()
60076028
echo ""
60086029
echo "AiMesh Node <b>${nodefriendlyname}</b> with MAC address <b>${node_label_mac}</b> requires update from <b>${1}</b> to <b>${2}</b> version."
60096030
echo "(<b>${1}</b> --> <b>${2}</b>)"
6031+
echo "Please click here to review the latest changelog:"
6032+
if "$NodeGNUtonFW"
6033+
then
6034+
Gnuton_changelogurl="$(GetLatestChangelogUrl "$FW_GITURL_RELEASE")"
6035+
echo "$Gnuton_changelogurl"
6036+
else
6037+
if [ "$node_firmver" -eq 3006 ]
6038+
then
6039+
changeLogURL="${CL_URL_3006}"
6040+
elif echo "$node_firmver" | grep -qE "^386[.]"
6041+
then
6042+
changeLogURL="${CL_URL_386}"
6043+
else
6044+
changeLogURL="${CL_URL_NG}"
6045+
fi
6046+
echo "$changeLogURL"
6047+
fi
60106048
echo "Automated update will be scheduled <b>only if</b> MerlinAU is installed on the node."
60116049
} > "$tempNodeEMailList"
60126050
fi

0 commit comments

Comments
 (0)