MCPcopy Create free account
hub / github.com/ScriptedAlchemy/tracedecay / hook_cursor_workspace_open

Function hook_cursor_workspace_open

src/hooks/cursor.rs:325–335  ·  view source on GitHub ↗

Cursor `workspaceOpen` hook handler. Notifies the daemon to run one-shot workspace catch-up. Fail-open.

()

Source from the content-addressed store, hash-verified

323///
324/// Notifies the daemon to run one-shot workspace catch-up. Fail-open.
325pub async fn hook_cursor_workspace_open() -> i32 {
326 let event = read_hook_event!();
327 let root = cursor_project_root_from_event(&event);
328 record_hook_invoked(root.as_deref(), HintAgent::Cursor, "workspaceOpen", &event);
329 notify_cursor_workspace_open(&event).await;
330 if let Some(root) = root.as_deref() {
331 memory_inject::regenerate_cursor_memory_rule(root).await;
332 }
333 println!("{}", serde_json::json!({}));
334 0
335}
336
337/// Pure decision logic for Cursor `subagentStart` hook events.
338///

Callers 1

handle_hook_commandFunction · 0.85

Calls 4

record_hook_invokedFunction · 0.85

Tested by

no test coverage detected