fix: install Hermes integration for profiles - #2343
Conversation
📝 WalkthroughWalkthroughHermes installation and uninstallation now process the main directory and all discovered profiles. Results include profile paths and cleanup counts. Tests cover asset installation, configuration preservation, plugin removal, and profile cleanup. ChangesHermes profile lifecycle
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant HermesIntegrationAction
participant HermesIntegrationTarget
participant ProfileDirectories
participant ProfileConfigurations
HermesIntegrationAction->>HermesIntegrationTarget: install or uninstall Hermes
HermesIntegrationTarget->>ProfileDirectories: discover profile directories
alt Installation
HermesIntegrationTarget->>ProfileDirectories: install plugin assets
HermesIntegrationTarget->>ProfileConfigurations: enable plugin entries
else Uninstallation
HermesIntegrationTarget->>ProfileDirectories: remove plugin directories
HermesIntegrationTarget->>ProfileConfigurations: disable plugin entries
end
HermesIntegrationTarget-->>HermesIntegrationAction: return paths and operation counts
Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/integration/tests.rs (1)
2610-2615: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winAssert
profile_config_pathsduring profile uninstallation.The result adds
profile_config_paths, but this test does not assert them. Add the expected default and workconfig.yamlpaths.Proposed test update
assert_eq!( result.profile_plugin_dirs, vec![default_plugin_dir.clone(), work_plugin_dir.clone()] ); + assert_eq!( + result.profile_config_paths, + vec![ + default_profile.join("config.yaml"), + work_profile.join("config.yaml"), + ] + ); assert_eq!(result.removed_profile_plugin_dirs, 2);
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 825501a6-e003-4b5f-96e9-8d9a493509f8
📒 Files selected for processing (4)
src/integration/actions.rssrc/integration/targets.rssrc/integration/tests.rssrc/integration/types.rs
|
Local verification update: cargo fmt --check passes with ZIG=/home/ubuntu/.local/zig/zig-x86_64-linux-0.15.2/zig. cargo test hermes -- --nocapture started compiling successfully with Zig 0.15.2 but did not reach test execution after a long local build window, so I stopped the local run and am relying on CI for the full Rust test signal. |
|
Apologies for opening this PR automatically before confirming the preferred workflow. I’ve marked it as draft so it does not appear ready for review or merge. |
Summary
Context
Herdr already installs Hermes into ~/.hermes, but Hermes profiles load plugins from their own profile homes. That means profile-backed Hermes sessions can miss the Herdr plugin and remain untracked.
Related existing PRs I found were closed unmerged and address session restore rather than profile plugin installation:
Test Plan