Skip to main content

Module parsed

Module parsed 

Source
Expand description

The Edit Parsed JSON tab: load and save parsed/{slug}/parsed_{tag}.json for an episode chosen from the usual Episode dropdown.

The config editors in crate::configs key off a file path the user picks from a list; this one derives its path from (slug, tag) instead, so it shares the Episode dropdown with Run Stage and Audio Preview.

Saving writes the file the way xil parse writes it — Style::INDENT2_UTF8 with no trailing newline — rather than the Style::INDENT2 the config editors use, so a hand-edit and a re-parse produce the same bytes and the non-ASCII punctuation in a script (—, “) is not rewritten as \uXXXX escapes.

Functions§

backup_path 🔒
{name}.bak beside the file itself, so parsed_S01E01.json backs up to parsed_S01E01.json.bak.
load
The file’s text for the editor, or a // comment explaining why not. Mirrors configs::load_config_file.
parsed_path
The parsed JSON path behind an Episode dropdown label, or the reason there is none.
save
Validate, back up and write. Returns the status line.