@turbo/codemod 1.7.1-canary.1 → 1.7.1-canary.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,5 +1,54 @@
1
1
  # Turborepo Codemods
2
2
 
3
- Turborepo provides Codemod transformations to help upgrade your Turborepo codebase when a feature is deprecated.
3
+ Turborepo provides Codemod transformations to help upgrade your Turborepo codebase.
4
4
 
5
5
  Codemods are transformations that run on your codebase programmatically. This allows for a large amount of changes to be applied without having to manually go through every file.
6
+
7
+ ## Commands
8
+
9
+ ### `migrate`
10
+
11
+ Updates your Turborepo codebase to the specified version of Turborepo (defaults to the latest), running any required codemods, and installing the new version of Turborepo.
12
+
13
+ ```
14
+ Usage: @turbo/codemod migrate|update [options] [path]
15
+
16
+ Migrate a project to the latest version of Turborepo
17
+
18
+ Arguments:
19
+ path Directory where the transforms should be applied
20
+
21
+ Options:
22
+ --from <version> Specify the version to migrate from (default: current version)
23
+ --to <version> Specify the version to migrate to (default: latest)
24
+ --install Install new version of turbo after migration (default: true)
25
+ --force Bypass Git safety checks and forcibly run codemods (default: false)
26
+ --dry Dry run (no changes are made to files) (default: false)
27
+ --print Print transformed files to your terminal (default: false)
28
+ -h, --help display help for command
29
+ ```
30
+
31
+ ### `transform`
32
+
33
+ Runs a single codemod on your codebase.
34
+
35
+ ```
36
+ Usage: @turbo/codemod transform [options] [transform] [path]
37
+
38
+ Apply a single code transformation to a project
39
+
40
+ Arguments:
41
+ transform The transformer to run
42
+ path Directory where the transforms should be applied
43
+
44
+ Options:
45
+ --force Bypass Git safety checks and forcibly run codemods (default: false)
46
+ --list List all available transforms (default: false)
47
+ --dry Dry run (no changes are made to files) (default: false)
48
+ --print Print transformed files to your terminal (default: false)
49
+ -h, --help display help for command
50
+ ```
51
+
52
+ ## Developing
53
+
54
+ To add a new transformer, run `pnpm add-transformer`, or [view the complete guide](./src/transforms/README.md).