Guest User

Untitled

a guest
Dec 4th, 2025
9
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.34 KB | None | 0 0
  1. {
  2. "hooks": {
  3. "PreToolUse": [
  4. {
  5. "matcher": "Grep",
  6. "hooks": [
  7. {
  8. "type": "prompt",
  9. "prompt": "Evaluate if this Grep call is searching for code symbols (class names, method names, function references, variable usages, interface implementations, type hierarchies) in Java/Kotlin/code files. If YES, return: {\"decision\": \"block\", \"systemMessage\": \"BLOCKED: Use JetBrains MCP tools for semantic code navigation instead of Grep. Available tools: ide_find_references (find usages), ide_find_definition (go-to-definition), ide_find_symbol (find by name), ide_find_implementations (interface/abstract implementations), ide_type_hierarchy (class relationships), ide_refactor_rename (safe renames), ide_diagnostics (code problems). These provide accurate semantic understanding vs text-based search.\"}. If searching for configuration values, text content, log patterns, or non-code patterns, return: {\"decision\": \"allow\"}.",
  10. "timeout": 15
  11. }
  12. ]
  13. },
  14. {
  15. "matcher": "mcp__jetbrains-index__.*",
  16. "hooks": [
  17. {
  18. "type": "command",
  19. "command": "powershell -Command \"Write-Host 'JetBrains MCP tool used - semantic code navigation engaged.' -ForegroundColor Green\""
  20. }
  21. ]
  22. }
  23. ]
  24. }
  25. }
Add Comment
Please, Sign In to add comment