From 698f9a60dfc4b710c5239f558cea468a5c8f8151 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Sat, 2 Aug 2025 10:50:52 +0200 Subject: [PATCH] Avoid rewrite itself https://github.com/alexbelgium/hassio-addons/issues/1991#issuecomment-3146327162 --- .templates/00-banner.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/.templates/00-banner.sh b/.templates/00-banner.sh index 379980c2f..e49340ebc 100755 --- a/.templates/00-banner.sh +++ b/.templates/00-banner.sh @@ -17,6 +17,7 @@ if ! bashio::supervisor.ping 2> /dev/null; then # Use environment variables instead of addon options echo "... convert scripts to use environment variables instead of addon options" while IFS= read -r scripts; do + [[ "$scripts" == *"00-banner.sh"* ]] && continue sed -i -e 's/bashio::config.has_value[[:space:]]*["'"'"']\([^"'"'"']*\)["'"'"']/[ ! -z "${\1:-}" ]/g' \ -e 's/bashio::config.true[[:space:]]*["'"'"']\([^"'"'"']*\)["'"'"']/[ ! -z "${\1:-}" ] \&\& [ "${\1:-}" = "true" ]/g' \ -e 's/\$(bashio::config[[:space:]]*["'"'"']\([^"'"'"']*\)["'"'"'])/${\1:-}/g' \