Skip to content

Commit c525d43

Browse files
authored
docs: improve migration skill workflow (#389)
1 parent 11a17b6 commit c525d43

2 files changed

Lines changed: 44 additions & 8 deletions

File tree

website/docs/en/guide/migration.mdx

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,40 @@ description: 'Migrate an existing project to Rstack CLI with the recommended mig
44

55
# Migrate to Rstack CLI
66

7-
To migrate an existing project, we recommend using the `migrate-to-rstack-cli` Skill. It inspects the project and automatically migrates supported tools used in the repository—including Rstack tools, Prettier, and Husky—to Rstack CLI.
7+
To migrate an existing project, we recommend using the `migrate-to-rstack-cli` Skill. It inspects the repository and migrates the Rstack toolchain, Prettier, Husky, and other supported tools to Rstack CLI.
88

99
## Use the migration skill
1010

11-
First, install the Skill:
11+
### Migrate in one pass
12+
13+
To migrate all supported tools in one pass, send this prompt to your coding agent:
14+
15+
```text
16+
Run `npx --yes skills@latest use rstackjs/rstack-cli@migrate-to-rstack-cli` and follow the generated Skill instructions to migrate this project to Rstack CLI.
17+
```
18+
19+
### Migrate in stages
20+
21+
If you want to keep each set of changes small and easy to review, migrate one tool at a time. Start by installing the Skill in your repository:
1222

1323
```bash
1424
npx skills add rstackjs/rstack-cli --skill migrate-to-rstack-cli
1525
```
1626

17-
Then ask your coding agent to perform the migration with this prompt:
27+
Then ask your coding agent to migrate a single tool. For example, start with Rslint:
1828

1929
```text
20-
Use the migrate-to-rstack-cli Skill to migrate this project to Rstack CLI.
30+
Use the migrate-to-rstack-cli Skill to migrate Rslint in this project to Rstack CLI, leaving all other tools unchanged.
2131
```
2232

33+
Once you have reviewed and validated the changes, move on to Rstest:
34+
35+
```text
36+
Use the migrate-to-rstack-cli Skill to migrate Rstest in this project to Rstack CLI, leaving all other tools unchanged.
37+
```
38+
39+
Repeat this process for each remaining tool.
40+
2341
## Supported tools
2442

2543
The Skill can directly migrate the following standalone tools:

website/docs/zh/guide/migration.mdx

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,40 @@ description: '使用推荐的迁移 Skill,将现有项目迁移到 Rstack CLI
44

55
# 迁移到 Rstack CLI \{#migrate-to-rstack-cli}
66

7-
迁移现有项目时,推荐使用 `migrate-to-rstack-cli` Skill。该 Skill 会分析项目,并自动将仓库中使用的 Rstack 工具及 Prettier、Husky 等受支持工具迁移到 Rstack CLI。
7+
迁移现有项目时,推荐使用 `migrate-to-rstack-cli` Skill。该 Skill 会分析仓库,并将其中受支持的工具(包括 Rstack 工具链、Prettier 和 Husky 等)迁移到 Rstack CLI。
88

99
## 使用迁移 Skill \{#use-the-migration-skill}
1010

11-
首先安装该 Skill:
11+
### 一次性迁移 \{#migrate-in-one-pass}
12+
13+
如需一次性迁移所有受支持的工具,请向 Coding Agent 发送以下 Prompt:
14+
15+
```text
16+
运行 `npx --yes skills@latest use rstackjs/rstack-cli@migrate-to-rstack-cli`,然后按照生成的 Skill 指令将当前项目迁移到 Rstack CLI。
17+
```
18+
19+
### 分批迁移 \{#migrate-in-stages}
20+
21+
如果希望每次改动更小、更便于审查,可以按工具分批迁移。首先,将 Skill 安装到当前仓库:
1222

1323
```bash
1424
npx skills add rstackjs/rstack-cli --skill migrate-to-rstack-cli
1525
```
1626

17-
安装完成后,向 Coding Agent 发送以下 Prompt
27+
然后让 Coding Agent 每次只迁移一种工具。例如,可以先迁移 Rslint
1828

1929
```text
20-
使用 migrate-to-rstack-cli Skill 将当前项目迁移到 Rstack CLI。
30+
使用 migrate-to-rstack-cli Skill 将当前项目中的 Rslint 迁移到 Rstack CLI,并保持其他工具不变
2131
```
2232

33+
审查并验证本次改动后,再迁移 Rstest:
34+
35+
```text
36+
使用 migrate-to-rstack-cli Skill 将当前项目中的 Rstest 迁移到 Rstack CLI,并保持其他工具不变。
37+
```
38+
39+
其余工具也可以按此方式依次迁移。
40+
2341
## 支持的工具 \{#supported-tools}
2442

2543
该 Skill 可以直接迁移以下独立工具:

0 commit comments

Comments
 (0)