# codemod/codemod

The CLI for codemods: scaffold, share, and run multi-step transformations of any size. First-class ast-grep support. Fast, reliable, polyglot.

Repository: https://github.com/codemod/codemod
Canonical: https://ross.abutalabs.com/products/codemod-codemod
Homepage: https://go.codemod.com/docs
Language: Rust
License: Apache-2.0
License Family: permissive
Topics: codemod, jscodeshift, migration, ts-morph, upgrade, ast-grep, cleanup, refactoring
Last push: 2026-09-02T23:51:28+00:00

## Health v2 (maintenance only)
Score: 89/100 (v2, computed 2026-09-03T02:39:23.370411+00:00)
- activity 100, release rhythm 88, longevity 67
- inputs: {"age_days": 950, "days_push": 0, "days_rel": 0, "gap_med": 1, "n_releases_24m": 166}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1082, forks 83 (observed 2026-09-03T02:15:10.108515+00:00)

## What it is
Codemod is an open-source CLI and workflow engine for scaffolding, testing, running, and publishing codemods—automated, multi-step code transformations for migrations, upgrades, and large-scale refactoring. It supports polyglot transformations with first-class ast-grep and JSSG (TypeScript AST pattern matching), and connects to a hosted registry and platform for sharing and orchestrating migrations across repositories.

## Use cases
- upgrade react or node across a large codebase
- migrate a design system like radix or tailwind to a new version
- automate i18n by converting static strings to translation keys
- run security or compliance remediation patches at scale
- scaffold and publish a reusable codemod to a registry
- orchestrate multi-step migrations across many repositories in CI

## When to choose
- you need to apply repetitive, large-scale code changes across many files or repos
- you want a CLI to author, test, and share AST-based transformations with ast-grep or jscodeshift
- you need orchestrated migrations with workflow configs, matrix strategies, and approval gates

## When to avoid
- you only need a one-off find-and-replace that sed or a simple script can handle
- you want a GUI-based refactoring tool rather than a CLI workflow
- your transformations are simple enough that an IDE's built-in refactorings suffice

## Facets
- artifact type: cli-tool
- maturity: active
- function: cli, developer-tools, workflow-automation, parser, build-tool
- domain: developer-tools, version-control
- platform: cli, cross-platform
- tags: codemod, code-migration, ast-transformation, ast-grep, jscodeshift, ts-morph, refactoring, framework-upgrade, registry, mcp, automation, command-line, nodejs

## Member repositories
- codemod/codemod (main) score 89

## Provenance
- Observed fields: from GitHub, fetched 2026-09-03T02:15:10.108515+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T06:53:13.925852+00:00, confidence not recorded.
  - readme: https://github.com/codemod/codemod (fetched 2026-09-03T02:15:10.108515+00:00, sha c13d63e9fd0c)
  - homepage: https://go.codemod.com/docs (fetched 2026-08-29T12:54:28.067981+00:00, sha 9d6a33d08878)
  - site_page: https://docs.codemod.com/oss-quickstart (fetched 2026-08-29T12:54:28.071827+00:00, sha 888963c16086)
  - site_page: https://docs.codemod.com/platform/quickstart (fetched 2026-08-29T12:54:28.074034+00:00, sha 5e46115c1d9c)
  - site_page: https://docs.codemod.com/changelog (fetched 2026-08-29T12:54:28.076047+00:00, sha 33f537e61d5b)
- Data as of 2026-08-30T08:39:29.467469+00:00.
