Repository navigation
v1.9.2 - File Backup & Cleanup
Critical Safety Improvements
Features
- File-level backup before pull: Automatic tar.gz backup of entire /config directory before any git pull operation
- Automatic backup cleanup: Keeps only the most recent backup after successful pull + config reload
- Merge conflict detection: Proper detection using
git ls-files --unmerged - Stash restoration on conflict: Local changes preserved when merge conflicts occur
Fixes
- Fixed merge conflict detection using unreliable
git diff --diff-filter=U - Stashed changes are now properly restored when conflicts occur
- Backups retained on any failure (config validation, reload) for emergency recovery
- Prevents filesystem bloat by cleaning up old backups
Safety Guarantees
- Before pull: Always creates file backup first (mandatory, pull fails if backup creation fails)
- On pull failure: All backups retained for potential restoration
- After reload: Only cleans up old backups after successful config reload
- Fallback recovery: If git becomes unusable, can restore from file backup
Test Coverage
- 56 unit tests (all passing)
- Merge conflict detection and notification tests
- Backup cleanup on success tests
- Backup retention on failure tests
- Stash restoration tests
Breaking Changes
None - fully backward compatible