Commit 835d1e5
fix(state): read jq-pretty-printed array values from the state file
get_state_value() matched with a single-line sed that broke on the
jq-pretty-printed state file, where array values span multiple lines and
`[...]` never matched. Flatten the state (newlines/tabs -> spaces) before
matching, then:
- array values are returned as one-line JSON with element quotes intact,
so callers can test membership against the exact quoted element;
- scalar values stay unquoted as before.
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 2861591 commit 835d1e5
1 file changed
Lines changed: 12 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
928 | 928 | | |
929 | 929 | | |
930 | 930 | | |
| 931 | + | |
| 932 | + | |
| 933 | + | |
| 934 | + | |
931 | 935 | | |
932 | | - | |
| 936 | + | |
| 937 | + | |
| 938 | + | |
| 939 | + | |
| 940 | + | |
| 941 | + | |
| 942 | + | |
| 943 | + | |
933 | 944 | | |
934 | 945 | | |
935 | 946 | | |
| |||
0 commit comments