1
Create a new codemod project
- Project directory
- Codemod type:
- Shell command workflow codemod
- JavaScript ast-grep codemod
- YAML ast-grep codemod
- Project name
- Description
- Author
- License type
- If your codemod is private
2
Explore the generated project
An example combined workflow package:
You can combine different codemod types in a single package. The
scripts/
and rules/
folders are conventional, not required—use any paths you prefer as long as you reference them correctly from workflow.yaml
.3
Understand an example workflow
The generated
workflow.yaml
will differ depending on the codemod type you select:Combined (jssg + yaml + shell + ai)
4
Validate & run your workflow
The
workflow validate
command checks syntax and schema compliance, but not logical correctness. Always test with real data to ensure expected behavior.