Skip to content

feat(init): 初始化 scope 选择改用数字 1/2#100

Merged
jeff-r2026 merged 1 commit into
Tencent:mainfrom
hsuchifeng:feat/init-scope-numeric-select
Jul 1, 2026
Merged

feat(init): 初始化 scope 选择改用数字 1/2#100
jeff-r2026 merged 1 commit into
Tencent:mainfrom
hsuchifeng:feat/init-scope-numeric-select

Conversation

@hsuchifeng

Copy link
Copy Markdown
Contributor

背景

teamai init 交互式选择 scope 时使用的是文本输入 Scope [user/project] (default: user),而紧随其后的角色选择流程用的是数字编号(1. ... / 2. ...)。两者风格不一致,容易让用户困惑。

改动

将 scope 提示改为与后续角色选择一致的数字编号:

Select scope:
  1. user    → ~/.teamai/
  2. project → <cwd>/.teamai/
Scope [1/2] (default: 1):
  • 默认值 1(user),直接回车行为不变。
  • 输入 2 选择 project。
  • 兼容旧的 user / project 文本输入。

仅改动 src/init.ts 的交互式分支;--scope flag 与 HTTP 初始化流程不受影响。

测试

  • npx tsc --noEmit 通过。
  • npx vitest run:1660 passed。3 个失败位于 import-repo-merge.test.ts,经 git stash 在 base 上复现,属改动前既有失败,与本次无关。

Made with Cursor

Align the init scope prompt with the numbered role-selection flow that
follows it. Users now pick 1 (user) or 2 (project) instead of typing
"user"/"project". Default is 1 (user); legacy text input still accepted
for backward compatibility.

Co-authored-by: Cursor <cursoragent@cursor.com>
@jeff-r2026 jeff-r2026 merged commit 42aaf7a into Tencent:main Jul 1, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants