From 169630f8c2e65c2e2563a1bc10e7c5d6bdc7a3ae Mon Sep 17 00:00:00 2001 From: Martinski4GitHub <119833648+Martinski4GitHub@users.noreply.github.com> Date: Sun, 21 Dec 2025 00:58:09 -0800 Subject: [PATCH 1/4] Update connmon.sh --- connmon.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/connmon.sh b/connmon.sh index 96aefd5..d239312 100644 --- a/connmon.sh +++ b/connmon.sh @@ -38,7 +38,7 @@ readonly SCRIPT_NAME="connmon" readonly SCRIPT_VERSION="v3.0.10" readonly SCRIPT_VERSTAG="25121620" -SCRIPT_BRANCH="master" +SCRIPT_BRANCH="develop" SCRIPT_REPO="https://raw.githubusercontent.com/AMTM-OSR/$SCRIPT_NAME/$SCRIPT_BRANCH" readonly SCRIPT_DIR="/jffs/addons/$SCRIPT_NAME.d" readonly SCRIPT_WEBPAGE_DIR="$(readlink -f /www/user)" From ced0c72e11cfdfbad88ffd457f229b82b1e56d32 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Jan 2026 21:22:33 +0000 Subject: [PATCH 2/4] Bump actions/checkout from 6.0.1 to 6.0.2 in the all-actions group Bumps the all-actions group with 1 update: [actions/checkout](https://github.com/actions/checkout). Updates `actions/checkout` from 6.0.1 to 6.0.2 - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v6.0.1...v6.0.2) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: 6.0.2 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: all-actions ... Signed-off-by: dependabot[bot] --- .github/workflows/Create-NewReleases.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/Create-NewReleases.yml b/.github/workflows/Create-NewReleases.yml index 4b78c3d..ac6b81e 100644 --- a/.github/workflows/Create-NewReleases.yml +++ b/.github/workflows/Create-NewReleases.yml @@ -19,7 +19,7 @@ jobs: steps: # 1--- Check out master so we tag the exact merge commit - name: Checkout source code - uses: actions/checkout@v6.0.1 + uses: actions/checkout@v6.0.2 with: fetch-depth: 0 ref: 'master' From 8384d783fdb325a922d32fd03a7561c4b78a1834 Mon Sep 17 00:00:00 2001 From: Martinski4GitHub <119833648+Martinski4GitHub@users.noreply.github.com> Date: Wed, 18 Feb 2026 01:21:14 -0800 Subject: [PATCH 3/4] New Functionality Initial code to support automatic script updates via AMTM. --- CHANGELOG.md | 4 ++++ README.md | 4 ++-- connmon.sh | 36 +++++++++++++++++++++++++++++++----- 3 files changed, 37 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index fb5a584..c94b907 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## v3.0.11 +Updated on 2026-Feb-18 +* NEW: Added code to support automatic add-on updates from AMTM. + ## v3.0.10 Updated on 2025-Dec-21 * FIXED: Bug fix in a CLI shell script function to get the full value of notification parameters from the configuration file. diff --git a/README.md b/README.md index 6c06ef3..8d1ee44 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # connmon -## v3.0.10 -### Updated on 2025-Dec-21 +## v3.0.11 +### Updated on 2026-Feb-18 ## About connmon is an internet connection monitoring tool for AsusWRT Merlin with charts for daily, weekly and monthly summaries. diff --git a/connmon.sh b/connmon.sh index d239312..07ad7e5 100644 --- a/connmon.sh +++ b/connmon.sh @@ -11,7 +11,7 @@ ## Forked from https://github.com/jackyaz/connmon ## ## ## ############################################################## -# Last Modified: 2025-Dec-16 +# Last Modified: 2026-Feb-18 #------------------------------------------------------------- ############## Shellcheck directives ############# @@ -36,8 +36,8 @@ ### Start of script variables ### readonly SCRIPT_NAME="connmon" -readonly SCRIPT_VERSION="v3.0.10" -readonly SCRIPT_VERSTAG="25121620" +readonly SCRIPT_VERSION="v3.0.11" +readonly SCRIPT_VERSTAG="26021800" SCRIPT_BRANCH="develop" SCRIPT_REPO="https://raw.githubusercontent.com/AMTM-OSR/$SCRIPT_NAME/$SCRIPT_BRANCH" readonly SCRIPT_DIR="/jffs/addons/$SCRIPT_NAME.d" @@ -75,6 +75,9 @@ readonly curlOutLogFile="/tmp/var/tmp/temp_${SCRIPT_NAME}_curl_OUT.LOG" readonly curlErrLogFile="/tmp/var/tmp/temp_${SCRIPT_NAME}_curl_ERR.LOG" readonly tmpCurlSEPstr="-------------------------------------------------------" +# To support automatic script updates from AMTM # +doScriptUpdateFromAMTM=true + # For daily CRON job to trim database # readonly defTrimDB_Hour=3 readonly defTrimDB_Mins=3 @@ -300,7 +303,8 @@ Update_Version() Print_Output true "New version of $SCRIPT_NAME available - $serverver" "$PASS" changelog="$(curl -fsL --retry 4 --retry-delay 5 "$SCRIPT_REPO/CHANGELOG.md" | sed -n "/$serverver"'/,/##/p' | head -n -1 | sed 's/## //')" printf "${BOLD}${UNDERLINE}Changelog\\n${CLEARFORMAT}%s\\n\\n" "$changelog" - elif [ "$isupdate" = "md5" ]; then + elif [ "$isupdate" = "md5" ] + then Print_Output true "MD5 hash of $SCRIPT_NAME does not match - hotfix available - $serverver" "$PASS" fi @@ -365,6 +369,23 @@ Update_Version() fi } +##-------------------------------------## +## Added by Martinski W. [2026-Feb-18] ## +##-------------------------------------## +ScriptUpdateFromAMTM() +{ + if ! "$doScriptUpdateFromAMTM" + then + printf "Automatic script updates via AMTM are currently disabled.\n\n" + return 1 + fi + if [ $# -gt 0 ] && [ "$1" = "check" ] + then return 0 + fi + Update_Version force unattended + return "$?" +} + ##----------------------------------------## ## Modified by Martinski W. [2025-Feb-09] ## ##----------------------------------------## @@ -6352,7 +6373,7 @@ then fi ##----------------------------------------## -## Modified by Martinski W. [2025-Dec-11] ## +## Modified by Martinski W. [2026-Feb-18] ## ##----------------------------------------## case "$1" in install) @@ -6579,6 +6600,11 @@ case "$1" in Update_Version force exit 0 ;; + amtmupdate) + shift + ScriptUpdateFromAMTM "$@" + exit "$?" + ;; postupdate) Create_Dirs Conf_Exists From 82dc24fe58dae0992a28e84d5da3d1569775c192 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Mar 2026 20:03:04 +0000 Subject: [PATCH 4/4] Bump softprops/action-gh-release in the all-actions group Bumps the all-actions group with 1 update: [softprops/action-gh-release](https://github.com/softprops/action-gh-release). Updates `softprops/action-gh-release` from 2.5.0 to 2.6.1 - [Release notes](https://github.com/softprops/action-gh-release/releases) - [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md) - [Commits](https://github.com/softprops/action-gh-release/compare/v2.5.0...v2.6.1) --- updated-dependencies: - dependency-name: softprops/action-gh-release dependency-version: 2.6.1 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: all-actions ... Signed-off-by: dependabot[bot] --- .github/workflows/Create-NewReleases.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/Create-NewReleases.yml b/.github/workflows/Create-NewReleases.yml index ac6b81e..c1bdcab 100644 --- a/.github/workflows/Create-NewReleases.yml +++ b/.github/workflows/Create-NewReleases.yml @@ -97,7 +97,7 @@ jobs: # 7--- Publish a GitHub Release with auto-generated notes - name: Create Release with Automated Release Notes - uses: softprops/action-gh-release@v2.5.0 + uses: softprops/action-gh-release@v2.6.1 with: token: ${{ secrets.GITHUB_TOKEN }} tag_name: ${{ steps.nextver.outputs.tag }}