ProxSave v0.13.1
🛠️ Smarter config upgrades, machine-readable upgrade output, and clearer upgrade UX
This patch release focuses on upgrade-time correctness and operator clarity, improving how backup.env is upgraded during binary upgrades. It adds a machine-readable JSON mode for config upgrades, wires automatic template-key merging into the upgrade flow, hardens multi-line env parsing/rendering, and refines prompts, previews, and error reporting for easier troubleshooting.
- Automatic config upgrade during binary upgrades: The upgrade flow now runs the newly installed binary to merge template changes into
backup.env, adding missing keys while preserving existing values. - Machine-readable upgrade mode: Added
--upgrade-config-jsonto emit structured config-upgrade results suitable for automation and tooling, with robust error handling and diagnostics. - Multi-line env value correctness: Implemented resilient parsing/rendering for block (multi-line) env values, preserving block entries and supporting multiple values per key.
- Refactored env parsing utilities: Introduced helpers (
parseEnvValues,splitKeyValueRaw,renderEnvValue,findClosingQuoteLine) and updatedcomputeConfigUpgradeto maintain fidelity of complex env structures. - Clearer prompts and operator messaging: Upgrade prompts now explicitly mention that a backup will be created and
backup.envmay be updated;printUpgradeFooterreports detailed upgrade outcomes or errors. - Improved previews and error reporting: Added a maximum JSON preview length for invalid JSON, improved parse errors to include the config path, and reported the starting line number for unterminated multi-line values.
- Test robustness across platforms: Normalized CRLF vs LF handling in tests to keep assertions deterministic on different environments.
Overall: safer and more transparent upgrades, better automation support via JSON output, and correct handling of complex backup.env values.