mirror of
https://github.com/pi-hole/pi-hole.git
synced 2024-11-15 02:42:58 +00:00
commit
121c93e822
1 changed files with 1 additions and 4 deletions
|
@ -2382,17 +2382,14 @@ FTLcheckUpdate() {
|
||||||
if [[ ${ftlLoc} ]]; then
|
if [[ ${ftlLoc} ]]; then
|
||||||
local FTLversion
|
local FTLversion
|
||||||
FTLversion=$(/usr/bin/pihole-FTL tag)
|
FTLversion=$(/usr/bin/pihole-FTL tag)
|
||||||
local FTLreleaseData
|
|
||||||
local FTLlatesttag
|
local FTLlatesttag
|
||||||
|
|
||||||
if ! FTLreleaseData=$(curl -sI https://github.com/pi-hole/FTL/releases/latest); then
|
if ! FTLlatesttag=$(curl -sI https://github.com/pi-hole/FTL/releases/latest | grep --color=never -i Location | awk -F / '{print $NF}' | tr -d '[:cntrl:]'); then
|
||||||
# There was an issue while retrieving the latest version
|
# There was an issue while retrieving the latest version
|
||||||
printf " %b Failed to retrieve latest FTL release metadata" "${CROSS}"
|
printf " %b Failed to retrieve latest FTL release metadata" "${CROSS}"
|
||||||
return 3
|
return 3
|
||||||
fi
|
fi
|
||||||
|
|
||||||
FTLlatesttag=$(grep 'Location' <<< "${FTLreleaseData}" | awk -F '/' '{print $NF}' | tr -d '\r\n')
|
|
||||||
|
|
||||||
if [[ "${FTLversion}" != "${FTLlatesttag}" ]]; then
|
if [[ "${FTLversion}" != "${FTLlatesttag}" ]]; then
|
||||||
return 0
|
return 0
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue