code-change-impact

code-change-impact is a cursor rule for Cursor from mghareeb/code-change-impact. It costs 122 tokens per session (900 once invoked), scanned A, original, MIT.

A code-review procedure that traces what parts of a project may be affected by a change. It follows imports, function calls, shared data structures, API responses, configuration, database changes, and other connections.

In plain words
What is it for?
Use it after a fix and before a commit, pull request, or push to check affected routes, commands, jobs, APIs, modules, and other runnable parts of the project.
Why use it?
A change that fixes one feature can quietly break another. This helps identify those knock-on effects and checks the project’s own build, test, type-check, and lint commands.

Cursor rule for Cursor

Written for Cursor: a Cursor rule (.mdc). Also seen: mentions Cursor.

Good fit Use it after a fix and before a commit, pull request, or push to check affected routes, commands, jobs, APIs, modules, and other runnable parts of the project.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/mghareeb/code-change-impact/code-change-impact
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/mghareeb/code-change-impact

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for code-change-impact

README.md
[![agentmods](https://agentmods.dev/badge/rules/mghareeb/code-change-impact/code-change-impact/github.svg)](https://agentmods.dev/rules/mghareeb/code-change-impact/code-change-impact)
Your own site
<a href="https://agentmods.dev/rules/mghareeb/code-change-impact/code-change-impact"><img src="https://agentmods.dev/badge/rules/mghareeb/code-change-impact/code-change-impact/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for code-change-impact

Your own site · 80×15
<a href="https://agentmods.dev/rules/mghareeb/code-change-impact/code-change-impact"><img src="https://agentmods.dev/badge/rules/mghareeb/code-change-impact/code-change-impact.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 122 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 900 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00122 $0.00900
Opus 5.5 $0.00049 $0.00360
Sonnet 5.5 $0.00024 $0.00180
Haiku 4.5 $0.00012 $0.00090

Measured 1mo ago against content hash 2132d66cb26c, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

code-change-impact scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

adapters/code-change-impact.mdc · 73 lines

How it starts

The opening of the file, as written. The whole thing — 73 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Code Change Impact (Cursor rule)

A fix is "done" only when you know what it touched besides the target. Find the ripples, then prove nothing else broke. Run against the VCS diff.

Procedure

0. Discover. Establish the repo root + diff; languages (from manifests); the project's own typecheck/build/test/lint commands (read scripts/Makefile/CI, don't guess); and the import style + path aliases. A repo may mix stacks.

1. Epicenter. git diff HEAD (or git diff <base>...HEAD); read the hunks. Classify each changed file: shared/core · public/exported symbol · type/interface/ schema · serialized contract (REST/GraphQL/DTO/proto) · config/registry · DB schema/migration · global config/styles · build/deps · generated/duplicated twin · or a local leaf.

2. Reverse dependencies. For each changed symbol, grep who imports the module and who calls the symbol (this language's import form). Build directly-impacted + transitively-impacted, then map to runnable surfaces (route/endpoint/command/job).

3. Behavioral impact. Per site: shape/signature/default/side-effect/invariant change, or internal/safe? Split build-caught ripples (typed langs) from silent ripples — cache/memo keys, changed default/sort, serialization/enum drift, global/persisted state, concurrency & transactions, locale/format, regex/ validation, flag defaults, theme/i18n. Check mirror/twin files: regenerate generated code, sync cross-language duplicated constants. One side edited without the other is an impact finding even if it compiles.

4. Verify. Run discovered commands cheapest-first, scaled to reach: typecheck → build → tests (prefer targeted) → lint. Then exercise the impacted surfaces and watch logs/errors. Green local ≠ deployed.

5. Report with the template below.

Report template (always)

# Code Change Impact: <one-line description>
## Verdict: SAFE | SAFE WITH CAVEATS | IMPACT FOUND
## Epicenter
- <file:line> — <coupling class> — <what changed>
## Blast radius
### Directly impacted
- <file / surface> — <route/endpoint/command> — <why> — risk: High|Med|Low
### Transitively impacted — <…> (or none)
## Mirror / twin files — <file to sync, in sync? yes/NO> (or none)
## Silent-risk callouts (build won't catch) — <…> (or none)
## Verification
- typecheck/build/tests: PASS/FAIL
- surfaces exercised: <list> → clean? errors?
## Residual risk & manual checklist
- [ ] <not auto-verifiable>

Read the full file on GitHub · 73 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 73 lines · 122 tokens per session scan A 2132d66cb26c

Subscribe to this mod's changes

code-change-impact is a cursor rule published in the GitHub repository mghareeb/code-change-impact (2 stars, last pushed 3mo ago), licensed MIT. It adds 122 tokens to every session and 900 once invoked, about $0.0005 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.