@theme-kit/cli
`theme-kit migrate`
theme-kit migrate <file> [options]Options
| Option | Description |
|---|---|
--file <path> | Legacy theme file to migrate (or pass positionally). |
--output <file> | Write the migrated theme to a new file. |
Examples
1# Migrate a single legacy theme
2theme-kit migrate themes/legacy.json
3
4# Migrate and write the current format to a new file
5theme-kit migrate \
6 themes/legacy.json \
7 --output themes/current.jsonWithout --output, the migrated JSON is printed to stdout — use it to diff
what changed before overwriting the original.
What migrations cover
The migration layer understands source and target versions, token renames,
color remapping, and arbitrary transforms. migrate runs every registered
migration between the file's version and the current schema. Back up your
themes before a bulk migration.
Exit codes
| Code | Meaning |
|---|---|
0 | Migrated (file written or printed). |
1 | Migrating the file failed. |
2 | No theme file supplied. |
Next: export.