Skip to content

samuelnyamukapa/modernize

v1.0.0Apache-2.0

Guided legacy-code modernization for GitHub Copilot: assess, map, mine business rules, plan, then upgrade, rewrite or rebuild with independent proof that the new code behaves like the old. A community port of Anthropic's code-modernization plugin.

assess

What am I dealing with? Inventory, complexity, debt, security and a recommended modernization pattern. Usage: /modernize:assess <system> [--show-secrets] | --portfolio <parent-dir>

brief

Write the phased Modernization Brief — the plan a steering committee approves and the build commands execute against. Usage: /modernize:brief <system> [target-stack]

extract-rules

Mine the business rules out of the code into testable Given/When/Then rule cards with file:line citations. Usage: /modernize:extract-rules <system> [module-pattern]

harden

Security scan of the legacy system with a reviewable remediation patch (OWASP, CWE, CVEs, secrets, injection). Usage: /modernize:harden <system> [--show-secrets]

map

Show me the structure — dependencies, data flow, entry points and business flows, as an interactive map. Usage: /modernize:map <system> [--graph <file>] [--no-describe]

preflight

Run this first — checks the environment, records where the code lives, and says what to fix before anything else runs. Usage: /modernize:preflight <system> [target-stack] [--source <path>]

reimagine

Rebuild the system from its extracted intent on a new architecture, with two human checkpoints. Usage: /modernize:reimagine <system> [target-vision]

review

Confirm or correct the business rules that need a person's judgement; the plan and the build read your answers. Usage: /modernize:review <system> [flagged|p0|all]

start

Start here — say what you want done with your code and get the plan and the first step. Usage: /modernize:start [system] [--source <path>]

status

Where am I? Progress, what is stale, and the exact next command to run — start here when unsure. Usage: /modernize:status <system>

transform

Rewrite one legacy module in the target stack, with tests that prove it behaves the same. Usage: /modernize:transform <system> [module] [target-stack]

uplift

Same-stack version uplift (e.g. .NET Framework 4.8 to .NET 8, Java 8 to 17) — keep the code, fix the version deltas, prove nothing changed. Usage: /modernize:uplift <system> [source-version] [target-version] [project-pattern]

verify

Prove the modernized code behaves like the legacy, with an independent re-check and one verdict per module. Usage: /modernize:verify <system> [module]