Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    Global Codebase Refactor

    1

    Makes one change across your whole codebase: maps it, plans every file, runs the app and tests before and after, fixes only what it broke, and reports file by file

    $5

    /mo

    Subscription · cancel anytime

    Secure checkout via Stripe

    • Always the latest version
    • Delivered live to your agent via MCP
    • Cancel anytime, access ends at period end
    Security scanned
    Global Codebase Refactor

    Global Codebase Refactor

    Example session with this skill installed

    Rename getUserName to getDisplayName everywhere in the codebase - code, tests and docs. The plan is approved in advance, go ahead and make the change.

    • Read your context and instructions
    • Compiled the global codebase refactor

    I've renamed getUserName to getDisplayName everywhere: 5 files, 10 occurrences. The app's output is the same as before and all 4 tests still pass. One thing you should know first: npm test was already broken before I touched anything, and it is still broken. Details are at the end.

    Codebase map

    Stack: Node.js 24, ES modules ("type": "module"), no dependencies. The tests use the built-in node:test runner.

    • Scripts: start runs node src/index.js; test runs node --test test/.
    • Layout: 8 files.
      • src/index.js (entry point)
      • src/users/user.js (where the function is defined)
      • src/notes/feed.js and src/notes/note.js (the two places it's used)
      • test/user.test.js and test/feed.test.js
      • README.md and package.json
    • Conventions: named exports, relative imports with the .js extension, camelCase function names.

    Blast radius

    I searched the whole project for getUserName, and also for related spellings (user_name, username, any case). The name only appears as a plain identifier:

    • No re-exports, no dynamic or string-based lookups, no aliases.
    • Nothing like getUserNames that could be caught by mistake.
    • getDisplayName didn't exist anywhere yet, so the new name can't clash with anything.

    The project is small enough to handle in one pass, so I didn't split it up.

    Plan vs. actual

    #FilePlanned changeDone
    1src/users/user.jsRename the exported function (line 1)Yes
    2src/notes/feed.jsUpdate the import (line 1) and the call (line 7)Yes
    3src/notes/note.jsUpdate the import (line 1) and the call (line 4)Yes
    4test/user.test.jsUpdate the import (line 3) and the 3 assertions (lines 5-7)Yes
    5README.mdUpdate the docs reference (line 3)Yes

    Nothing else changed

    • src/index.js and test/feed.test.js never referenced the function directly, so I left them alone.
    • I didn't edit package.json.
    • The function's behaviour and the test descriptions are the same as before.

    A search after the change finds 0 remaining getUserName and 10 getDisplayName, which matches the 10 original occurrences.

    Baseline vs. final

    CheckBeforeAfter
    npm startPrints 3 lines (Engines - by Ada Lovelace, Compilers - by grace, Draft - by Guest), exit 0Same 3 lines, exit 0
    npm testFails before any test runs (see below), exit 1Same failure, exit 1
    Tests run directly: node --test test/feed.test.js test/user.test.js4 of 4 pass4 of 4 pass

    No new failures, so there were no regressions to fix.

    Caveat: npm test is broken, and it isn't caused by this change

    On Node 24, node --test test/ treats test/ as a module path, so it stops with Cannot find module '...\notes-app\test' before any test runs. That's why I checked the tests by naming the files directly.

    I left the script as it was because it was failing before I started and it's outside this rename. The one-line fix is to change the script to node --test "test/**/*.test.js" (or node --test with no path). Want me to make that change?

    $5/mo

    Subscription · always the latest version

    • Secure checkout via Stripe
    • Cancel anytime
    • Delivered live via MCP

    About this skill

    For changes that touch more than one file: renaming something everywhere, deleting a feature end to end, adding attributes across every component, migrating a convention. It treats the change as a project rather than a find-and-replace. It reads the stack and maps the codebase, measures the blast radius, writes a file-level plan, and runs the app and the test suite to get a baseline before it edits anything.

    What it does

    It applies the change section by section, then runs the app and the tests again and compares them with the baseline. Anything that passed before and fails now is a regression, and it fixes only those. Failures that were there before are reported, not quietly "fixed". It ends with a plan-versus-actual table, every file changed, the before-and-after results of the run, and anything it found along the way that is outside the change.

    Try it first

    In a repo with tests, say "rename getUserName to getDisplayName everywhere, code, tests and docs". Check that the report shows a baseline run before the edit and the same result after.

    What it needs

    Read and write access to the repo, and Bash to run your build, dev script and tests. Node, Python, Rust or whatever your project uses, as long as there's a command to run it. No network access is needed beyond what your own build needs.

    It needs a runnable project: without a build or test command it can only check the change by reading the code, and it says so. It fixes regressions it caused, not pre-existing failures, which it reports and leaves for you to decide on. Very large codebases are split into sections of up to 30 files, so a sweeping change takes several passes. Changes that need a database migration or deployment work are planned and flagged, not run.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Free forever

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 27 days ago

    Permissions

    Read Files
    Write Files
    Terminal / Shell
    Listed27 days ago

    What's inside

    Frequently Asked Questions

    Makes one change across your whole codebase: maps it, plans every file, runs the app and tests before and after, fixes only what it broke, and reports file by file

    This skill uses the open SKILL.md standard. Use it through an MCP-compatible agent connected to Agensi, and check the compatibility information on this page for confirmed agents and required capabilities.

    Connect your AI agent to Agensi through MCP, then ask it to use Global Codebase Refactor on your task. Your agent loads the latest approved version each time. Paid skills require a purchase or active subscription. Skill files are not available for download; your licence does not allow you to save, copy or export any part of a skill.

    New in Code Quality & Review