mirror of
https://github.com/mag37/dockcheck.git
synced 2026-04-21 11:50:43 +00:00
compat-fixes to arrays
This commit is contained in:
@@ -17,6 +17,7 @@
|
|||||||
___
|
___
|
||||||
## :bell: Changelog
|
## :bell: Changelog
|
||||||
|
|
||||||
|
- **v0.4.5**: Bugfixes, compatibility changes to timeout and arrays.
|
||||||
- **v0.4.3**: Added timeout option to skip container if registry check takes too long (10s default).
|
- **v0.4.3**: Added timeout option to skip container if registry check takes too long (10s default).
|
||||||
- **v0.4.1**: Syntax and logic cleanups, bugfixes on multi compose and env-files.
|
- **v0.4.1**: Syntax and logic cleanups, bugfixes on multi compose and env-files.
|
||||||
- **v0.4.0**: Reworked selfupdate (auto git/curl/wget), general syntax cleanup, added -v for version.
|
- **v0.4.0**: Reworked selfupdate (auto git/curl/wget), general syntax cleanup, added -v for version.
|
||||||
|
|||||||
+6
-4
@@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
VERSION="v0.4.5"
|
VERSION="v0.4.5"
|
||||||
### ChangeNotes: Bugfix for non coreutils architectures that dont have timeout
|
### ChangeNotes: Compatability changes to arrays and timeout.
|
||||||
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"
|
||||||
|
|
||||||
@@ -245,9 +245,11 @@ for i in $(docker ps $Stopped --filter "name=$SearchName" --format '{{.Names}}')
|
|||||||
done
|
done
|
||||||
|
|
||||||
### Sort arrays alphabetically
|
### Sort arrays alphabetically
|
||||||
readarray -td '' NoUpdates < <(printf '%s\0' "${NoUpdates[@]}" | sort -z -n)
|
IFS=$'\n'
|
||||||
readarray -td '' GotUpdates < <(printf '%s\0' "${GotUpdates[@]}" | sort -z -n)
|
NoUpdates=($(sort <<<"${NoUpdates[*]}"))
|
||||||
readarray -td '' GotErrors < <(printf '%s\0' "${GotErrors[@]}" | sort -z -n)
|
GotUpdates=($(sort <<<"${GotUpdates[*]}"))
|
||||||
|
unset IFS
|
||||||
|
|
||||||
|
|
||||||
### Define how many updates are available
|
### Define how many updates are available
|
||||||
UpdCount="${#GotUpdates[@]}"
|
UpdCount="${#GotUpdates[@]}"
|
||||||
|
|||||||
Reference in New Issue
Block a user