How hgalexx/hg.savehistory works
Hg.SaveHistory is a Windows desktop application for managing file-save snapshots through game- or application-specific engines. Users create a profile in the wizard, configure its engine, then use the main window to back up, restore, archive, delete, and organize snapshots. Engine scripts run through Lua; watcher-driven automatic backups and optional screenshots extend that workflow. The tree and excerpts establish the main UI, engine, script, settings, and hotkey components. Several feature links are documented in the README because their implementation details were not sampled.
Main entry points: FormMain.cs Main window · LuaManager.cs Lua runtime · Engine.cs Engine API · EngineSnapshot.cs Snapshot model
Components 22
Profile setup
- Profile wizard
Hg.SaveHistory/Wizards/FormWizardNewProfile.cs - Engine discovery
Hg.SaveHistory/Managers/EngineScriptManager.cs - Engine scripts
Hg.SaveHistory/Types/EngineScript.cs - Script files
Hg.SaveHistory/Types/EngineScriptFile.cs - Profile data
Hg.SaveHistory/Types/ProfileFile.cs
Snapshot runtime
- Main window
Hg.SaveHistory/Forms/FormMain.cs - Lua runtime
Hg.SaveHistory/Managers/LuaManager.cs - Engine API
Hg.SaveHistory/API/Engine.cs - Snapshot model
Hg.SaveHistory/API/EngineSnapshot.cs - Snapshot categories
Hg.SaveHistory/API/EngineSnapshotCategory.cs - Backup and restore
Hg.SaveHistory/API/BackupHelper.cs - Watcher manager
Hg.SaveHistory/Managers/WatcherManager.cs - Engine watcher
Hg.SaveHistory/API/EngineWatcher.cs - Screenshot helper
Hg.SaveHistory/API/ScreenshotHelper.cs
Application controls
- Hotkey manager
Hg.SaveHistory/Managers/HotKeysManager.cs - Settings manager
Hg.SaveHistory/Managers/SettingsManager.cs - Settings model
Hg.SaveHistory/Types/Settings.cs - Snapshot cleanup
Hg.SaveHistory/Controls/AutoCleanupControl.cs - Sound notifications
Hg.SaveHistory/Managers/SoundManager.cs
Support services
- Logging
Hg.SaveHistory/Utilities/Logger.cs - Save files
Other components
- User
Connections 28
- User → Profile wizard: creates profile
Hg.SaveHistory/Wizards/FormWizardNewProfile.cs - Profile wizard → Engine discovery: selects engine
Hg.SaveHistory/Wizards/FormWizardNewProfile.cs - Engine discovery → Engine scripts: loads scripts
Hg.SaveHistory/Managers/EngineScriptManager.cs - Engine discovery → Script files: collects files
Hg.SaveHistory/Managers/EngineScriptManager.cs - Profile wizard → Profile data: configures profile
Hg.SaveHistory/Wizards/FormWizardNewProfile.cs - User → Main window: manages snapshots
- Main window → Lua runtime: opens profile
Hg.SaveHistory/Forms/FormMain.cs - Lua runtime → Engine API: creates engine
Hg.SaveHistory/Managers/LuaManager.cs - Lua runtime → Engine scripts: loads scripts
Hg.SaveHistory/Managers/LuaManager.cs - Main window → Profile data: opens profile
Hg.SaveHistory/Forms/FormMain.cs - Lua runtime → Profile data: loads settings
Hg.SaveHistory/Managers/LuaManager.cs - Lua runtime → Snapshot model: loads snapshots
Hg.SaveHistory/Managers/LuaManager.cs - Main window → Backup and restore: performs actions
- Main window → Snapshot model: displays snapshots
Hg.SaveHistory/Forms/FormMain.cs - Engine API → Snapshot model: holds snapshots
Hg.SaveHistory/API/Engine.cs - Engine API → Snapshot categories: holds categories
Hg.SaveHistory/API/Engine.cs - Main window → Watcher manager: manages auto-backup
Hg.SaveHistory/Forms/FormMain.cs - Watcher manager → Engine watcher: uses watchers
Hg.SaveHistory/Managers/WatcherManager.cs - Engine API → Screenshot helper: configures screenshots
Hg.SaveHistory/API/Engine.cs - Main window → Screenshot helper: captures screenshots
Hg.SaveHistory/Forms/FormMain.cs - Main window → Hotkey manager: manages hotkeys
Hg.SaveHistory/Forms/FormMain.cs - Hotkey manager → Snapshot model: selects snapshots
- Main window → Settings manager: uses settings
Hg.SaveHistory/Forms/FormMain.cs - Settings manager → Settings model: loads and saves
Hg.SaveHistory/Managers/SettingsManager.cs - Main window → Snapshot cleanup: configures cleanup
Hg.SaveHistory/Forms/FormMain.cs - Main window → Sound notifications: plays notifications
Hg.SaveHistory/Forms/FormMain.cs - Backup and restore → Save files: operates on
- Watcher manager → Save files: watches files