Installation
Install and set up Codegen in your development environment.
Prerequisites
We recommend using uv for installation. If you haven’t installed uv
yet:
Installing Codegen
This makes the codegen
command available globally in your terminal, while keeping its dependencies isolated.
Quick Start
Let’s walk through a minimal example of using Codegen in a project:
-
Navigate to your repository:
-
Initialize Codegen in your project with codegen init:
This creates a
.codegen/
directory with: -
Create your first codemod with codegen create:
The
-d
flag incodegen create
generates an AI-powered implementation. This requires a Github account registered on codegen.sh -
Run your codemod with codegen run:
-
Reset any filesystem changes (excluding
.codegen/*
) with codegen reset:
Next Steps
IDE Integration
Learn how to use Codegen effectively in VSCode, Cursor, and other IDEs.
Tutorials
Follow step-by-step tutorials for common code transformation tasks.
Work with AI
Leverage AI assistants like Copilot, Cursor and Devin
Guides
Learn more about building with Codegen
For more help, join our community Slack or check the FAQ.
Was this page helpful?