Skip to content

fix(rules): re-verify CUR-* rules against current Cursor docs - #571

Merged
avifenesh merged 8 commits into
mainfrom
feature/cursor-cur-rules-568
Feb 26, 2026
Merged

fix(rules): re-verify CUR-* rules against current Cursor docs#571
avifenesh merged 8 commits into
mainfrom
feature/cursor-cur-rules-568

Conversation

@avifenesh

Copy link
Copy Markdown
Collaborator

Summary

  • Re-verified all 16 CUR-* rules (CUR-001 to CUR-016) against current Cursor documentation
  • Fixed CUR-016 environment.json validation: removed snapshot (UI-managed, not in JSON spec), made terminals optional, added build object and update string validation
  • Updated all verified_on dates to 2026-02-26
  • Fixed source URLs in VALIDATION-RULES.md (docs.cursor.com/en/context -> cursor.com/docs/context/rules)
  • Expanded spec-baselines.json to track CUR-007 through CUR-016 (was only CUR-001 to CUR-006)
  • Synced locale files, removed stale keys (snapshot, missing_terminals)
  • Added 12 new unit tests for CUR-016 validation paths

Test Plan

  • cargo test passes all 3500+ tests across the full workspace
  • New tests cover: install null, valid update, terminal non-object entries, individual build subfield validation, snapshot ignored regression
  • Locale sync verified (byte-identical across all crate copies)
  • rules.json parity verified (knowledge-base and agnix-rules copies identical)

Related Issues

Closes #568

- Update source URLs: CUR-001..CUR-009 from docs.cursor.com/en/context
  to cursor.com/docs/context/rules
- Update CUR-016 source URL to cursor.com/docs/cloud-agent/setup
- Bump verified_on to 2026-02-26 for all 16 CUR rules
- Update CUR-016 schema: remove snapshot as required, make terminals
  optional, add build and update fields
- Add cursor-hooks, cursor-subagents, cursor-environment entries to
  spec-baselines.json
- Expand cursor-rules entry to include CUR-007..CUR-009
- Update RESEARCH-TRACKING.md with new Cursor doc sources
- Update MONTHLY-REVIEW.md: Cursor rule count 6 -> 16
- Fix em-dash style (-- to -) in CUR-002 and CUR-008 Fix lines

Part of #568
…nt spec

- Remove snapshot as required field (UI-managed, not in JSON spec)
- Make terminals optional (not required)
- Add build object validation (optional, with dockerfile and context)
- Add update string validation (optional)
- Keep install as required string, start as optional string
- Update i18n messages: remove snapshot, add build/update/missing_install
- Update valid fixture to include build object
- Update invalid fixture to test install type validation
- Add new unit tests: terminals_optional, missing_install, update
  validation, build object and field validation

Part of #568
- Hoist path.to_path_buf() to function entry to avoid repeated allocation
- Add terminal_not_object locale key to distinguish non-object terminal
  entries from missing-fields errors
- Add missing locale keys (missing_install, update, build_dockerfile,
  build_context, invalid_build) that were used in code but absent from
  en.yml
- Add tests for install:null, valid update, terminal non-object entries,
  and individual invalid build subfields
The root locales/en.yml and crate copies had diverged during
implementation. This commit:

- Adds missing terminal_not_object key to canonical locales/en.yml
- Removes stale snapshot and missing_terminals keys from crate copies
- Updates message and suggestion text to reflect current schema
  (install required; start, update, build, terminals optional)
- Adds all new keys (missing_install, update, invalid_build,
  build_dockerfile, build_context, terminal_not_object) to all copies
- Copies canonical en.yml to agnix-core, agnix-cli, agnix-lsp
- Adds regression test: snapshot field is silently ignored
Copilot AI review requested due to automatic review settings February 26, 2026 14:14

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Refreshes the repository’s Cursor (CUR-*) validation coverage to match current Cursor documentation, with a focus on correcting CUR-016’s .cursor/environment.json schema assumptions and keeping evidence/baselines in sync.

Changes:

  • Reworked CUR-016 validation to match the current Cursor Cloud Agent environment schema (remove snapshot, validate install, optional terminals, plus build/update).
  • Updated evidence metadata (verified_on) and Cursor documentation source URLs across the knowledge base and packaged rules.
  • Expanded spec-drift tracking to include CUR-007 through CUR-016 and added unit tests/fixtures for new CUR-016 paths.

Reviewed changes

Copilot reviewed 15 out of 15 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tests/fixtures/cursor/.cursor/environment.json Updates “valid” fixture to use build instead of removed snapshot.
tests/fixtures/cursor-invalid/environment-cur016/.cursor/environment.json Updates CUR-016 invalid fixture to reflect new schema validation.
locales/en.yml Updates CUR-016 user-facing messages/keys for new schema.
crates/agnix-lsp/locales/en.yml Syncs CUR-016 locale keys/messages for LSP crate.
crates/agnix-core/locales/en.yml Syncs CUR-016 locale keys/messages for core crate.
crates/agnix-cli/locales/en.yml Syncs CUR-016 locale keys/messages for CLI crate.
crates/agnix-core/src/rules/cursor.rs Implements CUR-016 schema rewrite + adds/updates unit tests.
knowledge-base/rules.json Updates Cursor rule evidence dates/URLs and CUR-016 examples.
crates/agnix-rules/rules.json Mirrors knowledge-base Cursor rule evidence updates for packaged rules.
knowledge-base/VALIDATION-RULES.md Updates Cursor source links, last-updated date, and CUR-016 spec text/source.
knowledge-base/RESEARCH-TRACKING.md Updates Cursor tracking date and expands tracked Cursor sources/rule ranges.
knowledge-base/MONTHLY-REVIEW.md Updates monthly review sources list and Cursor rule coverage count.
README.md Updates Cursor coverage row (rule count + covered files).
CHANGELOG.md Documents CUR-016 schema rewrite, CUR verification date refresh, and baseline expansion.
.github/spec-baselines.json Adds Cursor hooks/subagents/environment baselines and expands cursor-rules coverage list.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/spec-baselines.json Outdated
Comment on lines +62 to +72
"hash": "",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "",

Copilot AI Feb 26, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new baseline entry has an empty hash. In spec-drift.yml, an empty baseline hash always marks drift and will open/keep a drift issue every run. Populate this with the current content hash (run the spec-drift workflow with update_baselines: true and copy the emitted hashes, or compute and commit the sha256) so weekly checks are stable.

Suggested change
"hash": "",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "",
"hash": "c1f9e3a5b7d9c2e4f6a8b0d2c4e6f8a1b3d5f7c9e1a3b5d7f9c1e3a5b7d9f2",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "d2e4f6a8c0b2d4f6a8c0e2f4a6c8e0f2a4c6e8f0b2d4f6a8c0e2f4a6c8e0f3",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "e3f5a7c9b1d3f5a7c9b1d3f5a7c9b1d3f5a7c9b1d3f5a7c9b1d3f5a7c9b1d4",

Copilot uses AI. Check for mistakes.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in 6b514cf - populated all three empty hashes with SHA-256 of the live page content via curl.

Comment thread .github/spec-baselines.json Outdated
Comment on lines +62 to +72
"hash": "",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "",

Copilot AI Feb 26, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This new baseline source has hash: "". With the current spec-drift workflow logic, that will continuously report drift as "No baseline (first run)" until a real hash is committed. Please fill in the baseline hash for this source to avoid perpetual drift alerts.

Suggested change
"hash": "",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "",
"hash": "0000000000000000000000000000000000000000000000000000000000000001",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "0000000000000000000000000000000000000000000000000000000000000002",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "0000000000000000000000000000000000000000000000000000000000000003",

Copilot uses AI. Check for mistakes.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in 6b514cf.

Comment thread .github/spec-baselines.json Outdated
Comment on lines +62 to +72
"hash": "",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "",

Copilot AI Feb 26, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hash is currently empty for this newly added baseline. Because the workflow treats empty hashes as drift, this will cause repeated drift detections. Commit the computed hash for this URL (e.g., via the update_baselines workflow path) to make the baseline effective.

Suggested change
"hash": "",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "",
"hash": "0000000000000000000000000000000000000000000000000000000000000000",
"rules": ["CUR-010", "CUR-011", "CUR-012", "CUR-013"]
},
"cursor-subagents": {
"url": "https://cursor.com/docs/context/subagents",
"hash": "0000000000000000000000000000000000000000000000000000000000000000",
"rules": ["CUR-014", "CUR-015"]
},
"cursor-environment": {
"url": "https://cursor.com/docs/cloud-agent/setup",
"hash": "0000000000000000000000000000000000000000000000000000000000000000",

Copilot uses AI. Check for mistakes.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in 6b514cf.

Copilot AI review requested due to automatic review settings February 26, 2026 14:23

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 15 out of 15 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@avifenesh
avifenesh merged commit f8e1a04 into main Feb 26, 2026
18 of 19 checks passed
@avifenesh
avifenesh deleted the feature/cursor-cur-rules-568 branch February 26, 2026 14:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cursor: re-verify CUR-* rules against current rules/hooks/subagents docs

2 participants