Compare commits

..

10 Commits

Author SHA1 Message Date
mag37
1f374b5003 clarifying ntfy.sh
"domain" is a bit misleading, so clarifying that https:// is needed. Might change to "NTFY_URL" in the future.
2025-07-27 15:06:35 +02:00
mag37
563dbb8b42 Label bugfix, search filtering fix (#216)
* search filtering fix
* skip recreation if no label when -l option used + clarification
* changed readme + help to correctly show help example
2025-07-25 10:35:49 +02:00
mag37
31bb2008b9 new logo 2025-07-19 00:41:43 +02:00
mag37
cfa74adc3d added new logo 2025-07-19 00:40:50 +02:00
Rasmus Lundsgaard
e2dbd69c5e first version of notification to Home Assistant (#213)
* first working version of notification to Home Assistant

* add documentation links

* update readme for notify_HA
2025-07-14 13:59:07 +02:00
mag37
98e996caa3 added paypay sponsor 2025-07-07 10:49:32 +02:00
mag37
a1e7446753 version bump + readme 2025-07-01 22:27:54 +02:00
op4lat
69c06de1bd Add DisplaySourcedFiles variable (#207)
* Add DisplaySourcedFiles variable to be used in source_if_exists and source_if_exists_or_fail functions
* Added return 0 as to not throw wrong exit code.
* Delete source_if_exists. source_if_exists_or_fail returns success or failure. Failure doesn't stop the script

---------

Co-authored-by: Elephant Quater <eq@cont.MSHOME>
Co-authored-by: mag37 <robin.ivehult@gmail.com>
2025-07-01 22:19:15 +02:00
mag37
d37e1a1024 Bugfixes for unbound variable, potential collision and config variable mismatch
Version bump to alert users of the latest bugfixes for unbound variable, potential collision and config variable mismatch.
2025-06-27 09:22:10 +02:00
vorezal
77f024bb81 Fix unbound variable, potential collision, and config variable. (#209)
* Fix unbound variable, potential collision, and config variable.

* Return 0 when notification functions finish successfully

---------

Co-authored-by: Matthew Oleksowicz <matt@everyoneneeds.it>
2025-06-27 09:10:31 +02:00
6 changed files with 89 additions and 41 deletions

View File

@@ -1,13 +1,15 @@
<p align="center"> <p align="center">
<img src="extras/dockcheck_logo_by_booYah187.png" width="160" title="dockcheck"> <img src="extras/dockcheck_colour.png" width="300" title="dockcheck">
</p> </p>
<p align="center"> <p align="center">
<img src="https://img.shields.io/badge/bash-4.3-green?style=flat-square&logo=gnubash" alt="bash"> <img src="https://img.shields.io/badge/bash-4.3-green?style=flat-square&logo=gnubash" alt="bash">
<a href="https://www.gnu.org/licenses/gpl-3.0.html"><img src="https://img.shields.io/badge/license-GPLv3-red?style=flat-square" alt="GPLv3"></a> <a href="https://www.gnu.org/licenses/gpl-3.0.html"><img src="https://img.shields.io/badge/license-GPLv3-red?style=flat-square" alt="GPLv3"></a>
<img src="https://img.shields.io/github/v/tag/mag37/dockcheck?style=flat-square&label=release" alt="release"> <img src="https://img.shields.io/github/v/tag/mag37/dockcheck?style=flat-square&label=release" alt="release">
<br>
<a href="https://ko-fi.com/mag37"><img src="https://img.shields.io/badge/-Ko--fi-grey?style=flat-square&logo=Ko-fi" alt="Buy me a Coffee"></a> <a href="https://ko-fi.com/mag37"><img src="https://img.shields.io/badge/-Ko--fi-grey?style=flat-square&logo=Ko-fi" alt="Buy me a Coffee"></a>
<a href="https://liberapay.com/user-bin-rob/donate"><img src="https://img.shields.io/badge/-LiberaPay-grey?style=flat-square&logo=liberapay" alt="LiberaPay"></a> <a href="https://liberapay.com/user-bin-rob/donate"><img src="https://img.shields.io/badge/-LiberaPay-grey?style=flat-square&logo=liberapay" alt="LiberaPay"></a>
<a href="https://github.com/sponsors/mag37"><img src="https://img.shields.io/badge/-Sponsor-grey?style=flat-square&logo=github" alt="Github Sponsor"></a> <a href="https://github.com/sponsors/mag37"><img src="https://img.shields.io/badge/-Sponsor-grey?style=flat-square&logo=github" alt="Github Sponsor"></a>
<a href="https://www.paypal.com/donate/?business=P2V5MCWRGCNBG&no_recurring=0&currency_code=SEK"><img src="https://img.shields.io/badge/-PayPal-grey?style=flat-square&logo=paypal" alt="PayPal donation"></a>
</p> </p>
<h2 align="center">CLI tool to automate docker image updates or notifying when updates are available.</h2> <h2 align="center">CLI tool to automate docker image updates or notifying when updates are available.</h2>
@@ -20,25 +22,18 @@
___ ___
## :bell: Changelog ## :bell: Changelog
- **v0.6.9**: #
- Bugfix: label logic didn't skip recreation (skipped pulling).
- Added comma separated search filtering so you can selectively search exactly which containers to check/update.
- eg: `dockcheck.sh -yp homer,dozzle`
- **v0.6.8**:
- Bugfix: Unbound variable in notify_v2.sh
- New option: "DisplaySourcedFiles" *config* added to list what files get sourced
- **v0.6.7**: Snooze feature, curl, and consolidation - **v0.6.7**: Snooze feature, curl, and consolidation
- Added snooze feature to delay notifications - Added snooze feature to delay notifications
- Added configurable default curl arguments - Added configurable default curl arguments
- Consolidated and standardized notify template update notifications - Consolidated and standardized notify template update notifications
- Added curl error handling - Added curl error handling
- **v0.6.6**: Notify_v2 bugfixes
- Clearer readme and error messages
- Sourcing templates from either project root or subdirectory
- Consistent newline handling
- Added (when using `-d`) days old message to notification title
- Added ntfy self hosted domain option to config
- jq fixes to templates (and properly using $jqbin)
- **v0.6.5**: Refactored notification logic. See notify_templates/notify_v2.sh for upgrade steps.
- Added helper functions to simplify sourcing files and executing functions if they exist.
- Created notify_v2.sh wrapper script.
- Simplified and consolidated notification logic within notify_v2.sh.
- Added support for notification management via environment variables.
- Moved notification secrets to **dockcheck.config**.
- Added retries to wget/curl to not get empty responses when github is slow.
___ ___
@@ -47,7 +42,7 @@ ___
## :mag_right: `dockcheck.sh` ## :mag_right: `dockcheck.sh`
``` ```
$ ./dockcheck.sh -h $ ./dockcheck.sh -h
Syntax: dockcheck.sh [OPTION] [part of name to filter] Syntax: dockcheck.sh [OPTION] [comma separated names to include]
Example: dockcheck.sh -y -x 10 -d 10 -e nextcloud,heimdall Example: dockcheck.sh -y -x 10 -d 10 -e nextcloud,heimdall
Options: Options:
@@ -142,6 +137,7 @@ Make certain your project directory is laid out as below. You only need the noti
│ ├── notify_discord.sh │ ├── notify_discord.sh
│ ├── notify_generic.sh │ ├── notify_generic.sh
│ ├── notify_gotify.sh │ ├── notify_gotify.sh
│ ├── notify_HA.sh
│ ├── notify_matrix.sh │ ├── notify_matrix.sh
│ ├── notify_ntfy.sh │ ├── notify_ntfy.sh
│ ├── notify_pushbullet.sh │ ├── notify_pushbullet.sh
@@ -168,7 +164,7 @@ copy it to `notify.sh` alongside the script, modify it to your needs! (notify.sh
#### Snooze feature: #### Snooze feature:
**Use case:** You wish to be notified of available updates in a timely manner, but do not require reminders after the initial notification with the same frequency. **Use case:** You wish to be notified of available updates in a timely manner, but do not require reminders after the initial notification with the same frequency.
e.g. *Dockcheck is scheduled to run every hour. You will receive an update notification within an hour of availability.* e.g. *Dockcheck is scheduled to run every hour. You will receive an update notification within an hour of availability.*
**Snooze enabled:** you will not receive another notification about updates for this container for a configurable period of time. **Snooze enabled:** you will not receive another notification about updates for this container for a configurable period of time.
**Snooze disabled:** you will receive additional notifications every hour. **Snooze disabled:** you will receive additional notifications every hour.
To enable snooze, uncomment the `SNOOZE_SECONDS` variable in your `dockcheck.config` file and set it to the number of seconds you wish to prevent duplicate alerts. To enable snooze, uncomment the `SNOOZE_SECONDS` variable in your `dockcheck.config` file and set it to the number of seconds you wish to prevent duplicate alerts.
@@ -185,6 +181,7 @@ If an update becomes available for an item that is not snoozed, notifications wi
- Read the [QuickStart](extras/apprise_quickstart.md) - Read the [QuickStart](extras/apprise_quickstart.md)
- [ntfy](https://ntfy.sh/) - HTTP-based pub-sub notifications. - [ntfy](https://ntfy.sh/) - HTTP-based pub-sub notifications.
- [Gotify](https://gotify.net/) - a simple server for sending and receiving messages. - [Gotify](https://gotify.net/) - a simple server for sending and receiving messages.
- [Home Assistant](https://www.home-assistant.io/integrations/notify/) - Connection to the notify [integrations](https://www.home-assistant.io/integrations/#notifications).
- [Pushbullet](https://www.pushbullet.com/) - connecting different devices with cross-platform features. - [Pushbullet](https://www.pushbullet.com/) - connecting different devices with cross-platform features.
- [Telegram](https://telegram.org/) - Telegram chat API. - [Telegram](https://telegram.org/) - Telegram chat API.
- [Matrix-Synapse](https://github.com/element-hq/synapse) - [Matrix](https://matrix.org/), open, secure, decentralised communication. - [Matrix-Synapse](https://github.com/element-hq/synapse) - [Matrix](https://matrix.org/), open, secure, decentralised communication.

View File

@@ -26,12 +26,13 @@
#CurlRetryDelay=1 # Time between curl retries #CurlRetryDelay=1 # Time between curl retries
#CurlRetryCount=3 # Max number of curl retries #CurlRetryCount=3 # Max number of curl retries
#CurlConnectTimeout=5 # Time to wait for curl to establish a connection before failing #CurlConnectTimeout=5 # Time to wait for curl to establish a connection before failing
#DisplaySourcedFiles=false # Display what files are being sourced/used
### Notify settings ### Notify settings
## All commented values are examples only. Modify as needed. ## All commented values are examples only. Modify as needed.
## ##
## Uncomment the line below and specify the notification channels you wish to enable in a space separated string ## Uncomment the line below and specify the notification channels you wish to enable in a space separated string
# NOTIFY_CHANNELS="apprise discord DSM generic gotify matrix ntfy pushbullet pushover slack smtp telegram" # NOTIFY_CHANNELS="apprise discord DSM generic HA gotify matrix ntfy pushbullet pushover slack smtp telegram"
# #
## Uncomment the line below and specify the number of seconds to delay notifications to enable snooze ## Uncomment the line below and specify the number of seconds to delay notifications to enable snooze
# SNOOZE_SECONDS=86400 # SNOOZE_SECONDS=86400
@@ -56,12 +57,16 @@
# GOTIFY_DOMAIN="https://gotify.domain.tld" # GOTIFY_DOMAIN="https://gotify.domain.tld"
# GOTIFY_TOKEN="token-value" # GOTIFY_TOKEN="token-value"
# #
# HA_ENTITY="entity"
# HA_TOKEN="token"
# HA_URL="https://your.homeassistant.url"
#
# MATRIX_ACCESS_TOKEN="token-value" # MATRIX_ACCESS_TOKEN="token-value"
# MATRIX_ROOM_ID="myroom" # MATRIX_ROOM_ID="myroom"
# MATRIX_SERVER_URL="https://matrix.yourdomain.tld" # MATRIX_SERVER_URL="https://matrix.yourdomain.tld"
# #
## ntfy.sh or your custom domain with no trailing / ## https://ntfy.sh or your custom domain with https:// and no trailing /
# NTFY_DOMAIN="ntfy.sh" # NTFY_DOMAIN="https://ntfy.sh"
# NTFY_TOPIC_NAME="YourUniqueTopicName" # NTFY_TOPIC_NAME="YourUniqueTopicName"
# #
# PUSHBULLET_URL="https://api.pushbullet.com/v2/pushes" # PUSHBULLET_URL="https://api.pushbullet.com/v2/pushes"
@@ -81,3 +86,4 @@
# TELEGRAM_CHAT_ID="mychatid" # TELEGRAM_CHAT_ID="mychatid"
# TELEGRAM_TOKEN="token-value" # TELEGRAM_TOKEN="token-value"
# TELEGRAM_TOPIC_ID="0" # TELEGRAM_TOPIC_ID="0"

View File

@@ -1,6 +1,6 @@
#!/usr/bin/env bash #!/usr/bin/env bash
VERSION="v0.6.7" VERSION="v0.6.9"
# ChangeNotes: snooze feature (see readme), curl arguments, cleanup. # ChangeNotes: bugfix label logic and added comma separated search filtering
Github="https://github.com/mag37/dockcheck" Github="https://github.com/mag37/dockcheck"
RawUrl="https://raw.githubusercontent.com/mag37/dockcheck/main/dockcheck.sh" RawUrl="https://raw.githubusercontent.com/mag37/dockcheck/main/dockcheck.sh"
@@ -14,20 +14,22 @@ ScriptPath="$(readlink -f "$0")"
ScriptWorkDir="$(dirname "$ScriptPath")" ScriptWorkDir="$(dirname "$ScriptPath")"
# Source helper functions # Source helper functions
source_if_exists() {
if [[ -s "$1" ]]; then source "$1"; fi
}
source_if_exists_or_fail() { source_if_exists_or_fail() {
[[ -s "$1" ]] && source "$1" if [[ -s "$1" ]]; then
source "$1"
[[ "${DisplaySourcedFiles:-false}" == true ]] && echo " * sourced config: ${1}"
return 0
else
return 1
fi
} }
# User customizable defaults # User customizable defaults
source_if_exists_or_fail "${HOME}/.config/dockcheck.config" || source_if_exists "${ScriptWorkDir}/dockcheck.config" source_if_exists_or_fail "${HOME}/.config/dockcheck.config" || source_if_exists_or_fail "${ScriptWorkDir}/dockcheck.config"
# Help Function # Help Function
Help() { Help() {
echo "Syntax: dockcheck.sh [OPTION] [part of name to filter]" echo "Syntax: dockcheck.sh [OPTION] [comma separated names to include]"
echo "Example: dockcheck.sh -y -x 10 -d 10 -e nextcloud,heimdall" echo "Example: dockcheck.sh -y -x 10 -d 10 -e nextcloud,heimdall"
echo echo
echo "Options:" echo "Options:"
@@ -119,8 +121,11 @@ while getopts "ayfFhiIlmMnprsuvc:e:d:t:x:" options; do
done done
shift "$((OPTIND-1))" shift "$((OPTIND-1))"
# Set $1 to a variable for name filtering later # Set $1 to a variable for name filtering later, rewriting if multiple
SearchName="${1:-}" SearchName="${1:-}"
if [[ ! -z "$SearchName" ]]; then
SearchName="^(${SearchName//,/|})$"
fi
# Check if there's a new release of the script # Check if there's a new release of the script
LatestSnippet="$(curl ${CurlArgs} -r 0-200 "$RawUrl" || printf "undefined")" LatestSnippet="$(curl ${CurlArgs} -r 0-200 "$RawUrl" || printf "undefined")"
@@ -568,8 +573,11 @@ if [[ -n "${GotUpdates:-}" ]]; then
ContOnlySpecific=$($jqbin -r '."mag37.dockcheck.only-specific-container"' <<< "$ContLabels") ContOnlySpecific=$($jqbin -r '."mag37.dockcheck.only-specific-container"' <<< "$ContLabels")
[[ "$ContOnlySpecific" == "null" ]] && ContRestartStack="" [[ "$ContOnlySpecific" == "null" ]] && ContRestartStack=""
printf "\n%bNow recreating (%s/%s): %b%s%b\n" "$c_teal" "$CurrentQue" "$NumberofUpdates" "$c_blue" "$i" "$c_reset"
# Checking if compose-values are empty - hence started with docker run # Checking if compose-values are empty - hence started with docker run
[[ -z "$ContPath" ]] && continue [[ -z "$ContPath" ]] && { echo "Not a compose container, skipping."; continue; }
# Checking if Label Only -option is set, and if container got the label
[[ "$OnlyLabel" == true ]] && { [[ "$ContUpdateLabel" != true ]] && { echo "No update label, skipping."; continue; } }
# cd to the compose-file directory to account for people who use relative volumes # cd to the compose-file directory to account for people who use relative volumes
cd "$ContPath" || { printf "\n%bPath error - skipping%b %s" "$c_red" "$c_reset" "$i"; continue; } cd "$ContPath" || { printf "\n%bPath error - skipping%b %s" "$c_red" "$c_reset" "$i"; continue; }
@@ -585,7 +593,6 @@ if [[ -n "${GotUpdates:-}" ]]; then
# Set variable when compose up should only target the specific container, not the stack # Set variable when compose up should only target the specific container, not the stack
if [[ $OnlySpecific == true ]] || [[ $ContOnlySpecific == true ]]; then SpecificContainer="$ContName"; fi if [[ $OnlySpecific == true ]] || [[ $ContOnlySpecific == true ]]; then SpecificContainer="$ContName"; fi
printf "\n%bNow recreating (%s/%s): %b%s%b\n" "$c_teal" "$CurrentQue" "$NumberofUpdates" "$c_blue" "$i" "$c_reset"
# Check if the whole stack should be restarted # Check if the whole stack should be restarted
if [[ "$ContRestartStack" == true ]] || [[ "$ForceRestartStacks" == true ]]; then if [[ "$ContRestartStack" == true ]] || [[ "$ForceRestartStacks" == true ]]; then
${DockerBin} ${CompleteConfs} stop; ${DockerBin} ${CompleteConfs} ${ContEnvs} up -d || { printf "\n%bDocker error, exiting!%b\n" "$c_red" "$c_reset" ; exit 1; } ${DockerBin} ${CompleteConfs} stop; ${DockerBin} ${CompleteConfs} ${ContEnvs} up -d || { printf "\n%bDocker error, exiting!%b\n" "$c_red" "$c_reset" ; exit 1; }

BIN
extras/dockcheck_colour.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 144 KiB

31
notify_templates/notify_HA.sh Executable file
View File

@@ -0,0 +1,31 @@
### DISCLAIMER: This is a third party addition to dockcheck - best effort testing.
NOTIFY_HA_VERSION="v0.1"
#
# This is an integration that makes it possible to send notifications via Home Assistant (https://www.home-assistant.io/integrations/notify/)
# You need to generate a long-lived access token in Home Sssistant to be used here (https://developers.home-assistant.io/docs/auth_api/#long-lived-access-token)
# Leave (or place) this file in the "notify_templates" subdirectory within the same directory as the main dockcheck.sh script.
# If you instead wish make your own modifications, make a copy in the same directory as the main dockcheck.sh script.
# Do not modify this file directly within the "notify_templates" subdirectory. Set HA_ENTITY, HA_URL and HA_TOKEN in your dockcheck.config file.
if [[ -z "${HA_ENTITY:-}" ]] || [[ -z "${HA_URL:-}" ]] || [[ -z "${HA_TOKEN:-}" ]]; then
printf "Home Assistant notification channel enabled, but required configuration variables are missing. Home assistant notifications will not be sent.\n"
remove_channel HA
fi
trigger_HA_notification() {
AccessToken="${HA_TOKEN}"
Url="${HA_URL}/api/services/notify/${HA_ENTITY}"
JsonData=$( "$jqbin" -n \
--arg body "$MessageBody" \
'{"title": "dockcheck update", "message": $body}' )
curl -S -o /dev/null ${CurlArgs} \
-H "Authorization: Bearer $AccessToken" \
-H "Content-Type: application/json" \
-d "$JsonData" -X POST $Url
if [[ $? -gt 0 ]]; then
NotifyError=true
fi
}

View File

@@ -1,4 +1,4 @@
NOTIFY_V2_VERSION="v0.3" NOTIFY_V2_VERSION="v0.4"
# #
# If migrating from an older notify template, remove your existing notify.sh file. # If migrating from an older notify template, remove your existing notify.sh file.
# Leave (or place) this file in the "notify_templates" subdirectory within the same directory as the main dockcheck.sh script. # Leave (or place) this file in the "notify_templates" subdirectory within the same directory as the main dockcheck.sh script.
@@ -139,6 +139,8 @@ send_notification() {
fi fi
[[ -n "${snooze}" ]] && cleanup_snooze "${Updates[@]}" [[ -n "${snooze}" ]] && cleanup_snooze "${Updates[@]}"
return 0
} }
### Set DISABLE_DOCKCHECK_NOTIFICATION=false in dockcheck.config ### Set DISABLE_DOCKCHECK_NOTIFICATION=false in dockcheck.config
@@ -187,14 +189,17 @@ dockcheck_notification() {
fi fi
fi fi
fi fi
return 0
} }
### Set DISABLE_NOTIFY_UPDATE_NOTIFICATION=false in dockcheck.config ### Set DISABLE_NOTIFY_NOTIFICATION=false in dockcheck.config
### to not send notifications when notify scripts themselves have updates. ### to not send notifications when notify scripts themselves have updates.
notify_update_notification() { notify_update_notification() {
if [[ ! "${DISABLE_NOTIFY_UPDATE_NOTIFICATION:-}" == "true" ]]; then if [[ ! "${DISABLE_NOTIFY_NOTIFICATION:-}" == "true" ]]; then
NotifyUpdateNotify=false NotifyUpdateNotify=false
NotifyError=false NotifyError=false
NotifyUpdates=()
UpdateChannels=( "${enabled_notify_channels[@]}" "v2" ) UpdateChannels=( "${enabled_notify_channels[@]}" "v2" )
@@ -207,14 +212,14 @@ notify_update_notification() {
LatestNotifyRelease="$(echo "$LatestNotifySnippet" | sed -n "/${VersionVar}/s/${VersionVar}=//p" | tr -d '"')" LatestNotifyRelease="$(echo "$LatestNotifySnippet" | sed -n "/${VersionVar}/s/${VersionVar}=//p" | tr -d '"')"
if [[ ! "${LatestNotifyRelease}" == "undefined" ]]; then if [[ ! "${LatestNotifyRelease}" == "undefined" ]]; then
if [[ "${!VersionVar}" != "${LatestNotifyRelease}" ]] ; then if [[ "${!VersionVar}" != "${LatestNotifyRelease}" ]] ; then
Updates+=("${NotifyScript}.sh ${!VersionVar} -> ${LatestNotifyRelease}") NotifyUpdates+=("${NotifyScript}.sh ${!VersionVar} -> ${LatestNotifyRelease}")
fi fi
fi fi
fi fi
done done
if [[ -n "${snooze}" ]] && [[ -f "${SnoozeFile}" ]]; then if [[ -n "${snooze}" ]] && [[ -f "${SnoozeFile}" ]]; then
for update in "${Updates[@]}"; do for update in "${NotifyUpdates[@]}"; do
read -a NotifyScript <<< "${update}" read -a NotifyScript <<< "${update}"
found=$(grep -w "${NotifyScript}" "${SnoozeFile}" || printf "") found=$(grep -w "${NotifyScript}" "${SnoozeFile}" || printf "")
if [[ -n "${found}" ]]; then if [[ -n "${found}" ]]; then
@@ -232,8 +237,8 @@ notify_update_notification() {
fi fi
if [[ "${NotifyUpdateNotify}" == "true" ]]; then if [[ "${NotifyUpdateNotify}" == "true" ]]; then
if [[ "${#Updates[@]}" -gt 0 ]]; then if [[ "${#NotifyUpdates[@]}" -gt 0 ]]; then
UpdToString=$( printf '%s\\n' "${Updates[@]}" ) UpdToString=$( printf '%s\\n' "${NotifyUpdates[@]}" )
UpdToString=${UpdToString%\\n} UpdToString=${UpdToString%\\n}
NotifyError=false NotifyError=false
@@ -247,12 +252,14 @@ notify_update_notification() {
printf "Attempted to send notification to channel ${channel}, but the function was not found. Make sure notify_${channel}.sh is available in the ${ScriptWorkDir} directory or notify_templates subdirectory.\n" printf "Attempted to send notification to channel ${channel}, but the function was not found. Make sure notify_${channel}.sh is available in the ${ScriptWorkDir} directory or notify_templates subdirectory.\n"
done done
[[ -n "${snooze}" ]] && [[ "${NotifyError}" == "false" ]] && update_snooze "${Updates[@]}" [[ -n "${snooze}" ]] && [[ "${NotifyError}" == "false" ]] && update_snooze "${NotifyUpdates[@]}"
fi fi
fi fi
UpdatesPlusDockcheck=("${Updates[@]}") UpdatesPlusDockcheck=("${NotifyUpdates[@]}")
UpdatesPlusDockcheck+=("dockcheck.sh") UpdatesPlusDockcheck+=("dockcheck.sh")
[[ -n "${snooze}" ]] && cleanup_snooze "${UpdatesPlusDockcheck[@]}" [[ -n "${snooze}" ]] && cleanup_snooze "${UpdatesPlusDockcheck[@]}"
fi fi
return 0
} }