一键导入
git-find-ticket-branch
Find a git branch by Linear ticket ID prefix (e.g., STU-15)
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Find a git branch by Linear ticket ID prefix (e.g., STU-15)
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Create or reuse a dedicated git worktree for a branch using a deterministic path layout
Create and maintain implementation progress documentation for a feature branch
Find the worktree path for a branch and create/reuse it when missing
Resolve a properly named git branch from a Linear ticket ID following the convention {type}/{ticket-id}-short-description
Push the current branch to the remote repository with upstream tracking
Fetch unresolved review threads and PR comments for the pull request tied to the resolved target branch
| name | git-find-ticket-branch |
| description | Find a git branch by Linear ticket ID prefix (e.g., STU-15) |
Find an existing git branch that corresponds to a Linear ticket ID.
Also report whether the branch already has an attached worktree and where it is located.
Branches follow the naming convention: {type}/{ticket-id}-{description}
Search for branches containing the ticket ID.
Fetch latest remote branches:
git fetch --all --prune
Search local and remote branches:
git branch -a | grep -i "{ticket-id}"
Parse results:
remotes/origin/ prefix for remote branchesResolve worktree mapping for each branch candidate:
git worktree list --porcelain
branch refs/heads/{branch} entriesworktree path when presentReturn the branch name and report:
List all matching branches with their last commit dates:
git for-each-ref --sort=-committerdate --format='%(refname:short) - %(committerdate:relative)' refs/heads refs/remotes | grep -i "{ticket-id}"
Ask the user which branch to use.
Report that no branch was found for this ticket ID.
Suggest possible actions:
git for-each-ref --sort=-committerdate --format='%(refname:short)' refs/heads | head -10
Provide:
git log {branch} -1 --oneline
For ticket STU-15:
Found branch: feat/STU-15-user-authentication
- Exists: locally and on origin
- Worktree: /Users/me/projects/my-repo/.opencode/.bbq-worktrees/feat-STU-15-user-authentication
- Last commit: abc1234 feat(api): add login endpoint (2 hours ago)