Skip to main content

Module hooks

Module hooks 

Source

Functionsยง

generate_compact_rewrite_script
generate_rewrite_script
install_agent_hook
install_project_rules
normalize_tool_path
Normalize paths from any client format to a consistent OS-native form. Handles MSYS2/Git Bash (/c/Users/... -> C:/Users/...), mixed separators, double slashes, and trailing slashes. Always uses forward slashes for consistency.
refresh_installed_hooks
Silently refresh all hook scripts for agents that are already configured. Called after updates and on MCP server start to ensure hooks match the current binary version.
to_bash_compatible_path