Repository navigation
feat: customizable worktree branch naming (#98) - #99
Merged
Merged
Conversation
Board-level naming presets + task-level override for worktree-isolated tasks: - Board settings: a branch-naming preset picker (task/标题+ID default, task/ID, prefix/ID, prefix/标题+ID) with a conditional prefix input and a live example preview. - Task form: an optional branch-name field shown for worktree tasks. It defaults to (and follows) the board-rule derivation until edited; clearing it restores the preset. The placeholder previews the rule in both modes (create mode renders the not-yet-minted id as the literal ID placeholder). Locked once execution history exists, like isolation. - taskboard_create tool accepts an explicit branch (taskboard_update stays read-only on execution config, matching the isolation edge). - Pre-#98 ledgers need no migration: absent fields resolve to the legacy byte-identical task/<标题>+<taskId> output; pin, collision fallback, multi-repo mirrors and successor-card semantics unchanged. Closes #98
cloader
force-pushed
the
feat/issue-98-branch-naming
branch
from
November 5, 2026 01:28
bd3766b to
5687921
Compare
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.
Closes #98
What
Worktree task branches are currently always
task/<标题>+<taskId>— a Chinese title yields a Chinese branch name. This PR makes the naming configurable at two levels:Board level (看板设置 → 分支命名): a naming preset picker —
task/标题+ID(default)task/修复登录+t-1a2b(pre-#98 behavior, byte-identical)task/IDtask/t-1a2b(pure ASCII)前缀/IDwork/t-1a2b前缀/标题+IDwork/修复登录+t-1a2bPrefix presets reveal a prefix input (sanitized with the same illegal-char rules, 20-code-point cap). A live example preview renders as you switch.
Task level (task form, worktree isolation): an optional branch-name field. It defaults to (and keeps following) the board-rule derivation while the title edits; typing stops the auto-follow; clearing it restores the preset. The placeholder previews the rule in both modes — create mode renders the not-yet-minted id as the literal
IDplaceholder. Once execution history exists the field locks, same rule as isolation (the branch is pinned by the first worktree creation).The
taskboard_createagent tool accepts the same explicitbranchargument;taskboard_updatestays read-only on execution config (matching the existing isolation edge).Compatibility
sanitizeBranchNamenow delegates tobuildBranchNameunder the factory preset and its existing test suite passes unchanged.+r<8hex>collision fallback, optimistic pin replacement (pinBranches), multi-repo per-repo pins, successor cards not inheriting branches./kept for multi-level names,.locksuffixes stripped, 60-code-point cap); garbage input fail-softs to the board preset.Tests
tests/issue-98.spec.ts— preset builder (legacy byte-equality regression), custom-name sanitizer spectrum, settings whitelist + accessor defaults.tests/issue-98-ui.spec.tsx— form field (default derivation, title follow-until-touched, locked state, create-mode payload), settings picker (prefix input, save body).tests/routes.spec.ts— create materialization, update swap/clear, execution-history lock.