Files
everything-claude-code/.cursor/rules/hooks-guidance.md
Affaan Mustafa 261332dc50 feat: add Cursor IDE support with pre-translated configs
Add complete .cursor/ directory with rules, agents, skills, commands,
and MCP config adapted for Cursor's format. This makes ecc-universal
a truly cross-IDE package supporting Claude Code, Cursor, and OpenCode.

- 27 rule files with YAML frontmatter (description, globs, alwaysApply)
- 13 agent files with full model IDs and readonly flags
- 30 skill directories (identical Agent Skills standard, no translation)
- 31 command files (5 multi-* stubbed for missing codeagent-wrapper)
- MCP config with Cursor env interpolation syntax
- README.md and MIGRATION.md documentation
- install.sh --target cursor flag for project-scoped installation
- package.json updated with .cursor/ in files and cursor keywords
2026-02-11 02:31:52 -08:00

37 lines
994 B
Markdown

---
description: "Guidance on achieving hook-like functionality in Cursor IDE"
alwaysApply: false
---
# Hooks Guidance for Cursor
Cursor does not have a native hooks system like Claude Code's PreToolUse/PostToolUse/Stop hooks. However, you can achieve similar automation through:
## Formatting on Save
Configure your editor settings to run formatters on save:
- **TypeScript/JavaScript**: Prettier, ESLint with `--fix`
- **Python**: Black, Ruff
- **Go**: gofmt, goimports
## Linting Integration
Use Cursor's built-in linter support:
- ESLint for TypeScript/JavaScript
- Ruff/Flake8 for Python
- golangci-lint for Go
## Pre-Commit Hooks
Use git pre-commit hooks (via tools like `husky` or `pre-commit`) for:
- Running formatters before commit
- Checking for console.log/print statements
- Running type checks
- Validating no hardcoded secrets
## CI/CD Checks
For checks that ran as Stop hooks in Claude Code:
- Add them to your CI/CD pipeline instead
- GitHub Actions, GitLab CI, etc.