Skip to content

Commit 08a0929

Browse files
author
codegen-bot
committed
.
1 parent a1a2027 commit 08a0929

File tree

1 file changed

+25
-1
lines changed

1 file changed

+25
-1
lines changed

README.md

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,34 @@ for function in codebase.functions:
2424

2525
Write code that transforms code. Codegen combines the parsing power of [Tree-sitter](https://tree-sitter.github.io/tree-sitter/) with the graph algorithms of [rustworkx](https://github.com/Qiskit/rustworkx) to enable scriptable, multi-language code manipulation at scale.
2626

27-
## Installation
27+
## Installation and Usage
2828
**This library requires Python 3.12 – 3.13.**
2929
```
30+
# Install inside existing project
3031
uv pip install codegen
32+
33+
# Install global CLI
34+
uv tool install codegen
35+
36+
# Create a codemod for a given repo
37+
cd path/to/repo
38+
codegen init
39+
codegen create test-function
40+
41+
# Run said codemod
42+
codegen run test-function
43+
44+
# Create an isolated venv with codegen => open jupyter
45+
codegen notebook
46+
```
47+
48+
## Usage
49+
50+
See [https://docs.codegen.com/introduction/getting-started] for a full tutorial.
51+
52+
```
53+
from codegen import Codebase
54+
3155
```
3256

3357
## Resources

0 commit comments

Comments
 (0)