Grab local FTL hash correctly from FTL's own version output, and grab one digit less for remote hashes (also in debug log)

Signed-off-by: Adam Warner <me@adamwarner.co.uk>
This commit is contained in:
Adam Warner 2022-11-14 22:09:26 +00:00
parent cdbe4c9b86
commit ba74051502
No known key found for this signature in database
GPG key ID: 872950F3ECF2B173
2 changed files with 5 additions and 5 deletions

View file

@ -314,9 +314,9 @@ check_ftl_version() {
local FTL_VERSION FTL_COMMIT FTL_BRANCH
echo_current_diagnostic "FTL version"
# Use the built in command to check FTL's version
FTL_VERSION=$(pihole-FTL -vv | grep -m 1 Version | awk '{printf $2}')
FTL_BRANCH=$(pihole-FTL -vv | grep -m 1 Branch | awk '{printf $2}')
FTL_COMMIT=$(pihole-FTL -vv | grep -m 1 Commit | awk '{printf $2}')
FTL_VERSION=$(pihole-FTL version)
FTL_BRANCH=$(pihole-FTL branch)
FTL_COMMIT=$(pihole-FTL --hash)
log_write "${TICK} Version: ${FTL_VERSION}"