You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[bug] Single-quoted ${var/pat/repl} inside $() command substitution is expanded (GNU: literal) - OMB iterate theme loses all prompt segments #416
The single-quoted sed program ${s/.../.../p;} must reach sed verbatim; under rubash it is expanded as shell parameter substitution (variable s unset -> empty), so sed runs with an empty program. The same text at top level (not inside $( )) and via "${1}" indirection is preserved - the leak is specific to the single-quoted ${...} form inside a command substitution in a script file.
GNU spec: single-quoted text is never subject to expansion - parse.y:5305 read_token_word() single-quote branch collects the body literally; command substitution bodies are re-parsed as fresh input (subst.c:7143 command_substitute) with the same quoting rules. Rust owner to map on the comsub body split path.
Impact
oh-my-bash iterate theme (themes/iterate/iterate.theme.sh:38-47) measures its prompt with a nested $(PS1="..." "$BASH" --norc -i | sed -n '${s/^\(.*\)exit$/\1/p;}'); the leak makes every measurement empty, the theme's cache check blanks new_PS1, and the stored PS1 loses ALL dynamic segments (GNU shows the full two-line prompt, rubash shows only the arrow). Confirmed on the interactive load sweep: rubash PS1 = \[\e[0;32m\]→\[\e[39m\] , GNU = full ± \w |master ?:1 ✗| \n→ prompt.
Activity
docs(corpus): themesweep lane (wt53) — 83-theme load + 82-theme rende…
fix(expand): single-quoted words keep integrity through pipeline and …
fix(tests): temp probe path and script +x in trap/comsub tests (#524/#…