Repository navigation
feat(线): 新增 line add-repo 并修复建线回滚遗留分支 - #80
Merged
Merged
Conversation
- 新增 dyro line add-repo:把一个已登记仓库加入现有开发线;子线保持不变,子线只能加入父线已有的仓库,基线与存储方式从父线派生。 - 锁顺序与 line retire 相同(身份锁、线合并锁、仓库锁),清单在合并锁内重读。 - 失败时只删除新建的目标及其变空的父目录。 - create、spawn、add-repo 回滚时删除本次用 -b 新建的分支,已有分支保持不动;路径清理失败时仍尝试删除并一并报告。
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Merged
This branch had an error being deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
内容
dyro line add-repo LINE REPO [--base REF] [--storage linked-worktree|anchor-reference] [--dry-run] [--yes]:把一个已登记的仓库加入现有开发线。line spawn一致),不接受--base/--storage。line retire相同:身份锁 → 该线合并锁 → 该仓 anchor 锁。清单在合并锁内重读,避免并发merge --push写远端锚点时用旧清单覆盖新加的仓库。line create/line spawn/line add-repo回滚遗留分支:回滚时删除本次用-b新建的分支,原本就有的分支保持不动。之前用另一个基线重试会静默复用遗留分支。_plan_repository_creation与_create_repository_worktree,create / spawn 行为不变。不包含:
repo remove/repo move、子线自动继承、新事件类型。验证
tests/test_line_add_repo.py15 项:顶层与子线、自定义基线、复用已有分支、重复与未登记仓库、父线加仓不改子线清单、未完成操作拦截、写入失败回滚(含分支清理、重试、anchor-reference、保留已有分支、路径清理失败仍报告分支、create 回滚)、dry-run、schema 4 远端锚点保留、CLI--yes。ruff check src tests experiments通过。