Skip to content

Debloat any Android or Google TV over Wi-Fi and get an Apple TV-style home.

addons/game-day: setup's report says 'nothing in the next 7 days' plainly

Justin Newman39b853f41d17
diff --git a/addons/game-day/setup.ps1 b/addons/game-day/setup.ps1
index 5b26e2149..73a5d9465 100644
--- a/addons/game-day/setup.ps1
+++ b/addons/game-day/setup.ps1
@@ -44,7 +44,7 @@ $bad = $false
foreach ($line in $lines) {
$f = $line -split '\|', 5
switch ($f[0]) {
- 'ok' { Write-Host (' {0,-22} {1,-14} ' -f $f[1], $f[2]) -NoNewline; Write-Host 'ok' -ForegroundColor Green -NoNewline; Write-Host " $($f[3]) $(if ($f[3] -eq '1') { 'entry' } else { 'entries' }), next $($f[4])"; $sent++ }
+ 'ok' { Write-Host (' {0,-22} {1,-14} ' -f $f[1], $f[2]) -NoNewline; Write-Host 'ok' -ForegroundColor Green -NoNewline; Write-Host " $($f[3]) $(if ($f[3] -eq '1') { 'entry' } else { 'entries' }), $(if ($f[4] -like 'nothing*') { $f[4] } else { "next $($f[4])" })"; $sent++ }
'fail' { Write-Host (' {0,-22} {1,-14} ' -f $f[1], $f[2]) -NoNewline; Write-Host $f[3] -ForegroundColor Red; $sent++; $failed = $true }
'error' { Write-Host (' ' + ($line -replace '^error\|[^|]*\|', '')) -ForegroundColor Red; $failed = $true; $bad = $true }
}
diff --git a/addons/game-day/setup.sh b/addons/game-day/setup.sh
index 8a9083f24..36f07e97f 100644
--- a/addons/game-day/setup.sh
+++ b/addons/game-day/setup.sh
@@ -48,7 +48,8 @@ while IFS= read -r LINE; do
IFS='|' read -r KIND A B C D <<< "$LINE"
case "$KIND" in
ok) E=entries; [ "$C" = 1 ] && E=entry
- printf ' %-22s %-14s \033[32mok\033[0m %s %s, next %s\n' "$A" "$B" "$C" "$E" "$D"; N=$((N + 1)) ;;
+ case "$D" in nothing*) ;; *) D="next $D" ;; esac
+ printf ' %-22s %-14s \033[32mok\033[0m %s %s, %s\n' "$A" "$B" "$C" "$E" "$D"; N=$((N + 1)) ;;
fail) printf ' %-22s %-14s \033[31m%s\033[0m\n' "$A" "$B" "$C"; N=$((N + 1)); STATUS=1 ;;
error) printf ' \033[31m%s\033[0m\n' "${LINE#error|*|}"; STATUS=1 ;;
esac