fix(spectrum): build the colour tables independently of KSH_ARRAYS

The table builder uses ${^codes} and the :^ zip flag, both of which
expand only element 0 when KSH_ARRAYS is set, leaving FG and BG empty.
The 256-iteration loop it replaced was option-independent.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Robby Russell
2026-09-07 07:53:20 -07:00
co-authored by Claude Opus 5
parent 5af2aadee2
commit db67ded96b
+1
View File
@@ -16,6 +16,7 @@ FX=(
# Build the tables with array operations instead of a 256-iteration loop
() {
setopt localoptions noksharrays
local -a codes fg bg
codes=({000..255})
fg=( "%{"$'\e'"[38;5;"${^codes}"m%}" )