mirror of
https://github.com/HKUDS/CLI-Anything.git
synced 2026-09-17 17:38:11 +08:00
One-shot commands start a fresh Session each run, so in-memory changes
were silently discarded without an explicit 'document save'. This ports
the same pattern already used in the Shotcut harness (commit 17a30ba):
- Add -s/--save flag to the cli() group
- Register ctx.call_on_close(_auto_save_callback)
- _auto_save_callback saves if session is modified and not in REPL mode