关于 linear-git
linear-git 是通过 linear-cli 将 Git 操作与 Linear 问题关联的技能。它可创建或检出问题分支、显示分支名,并从当前分支获取问题上下文。
主要功能
- 01检出或创建问题分支
- 02显示问题对应的分支名
- 03创建分支但不检出
- 04从当前分支获取问题上下文
适用场景
- 01为 Linear 问题设置分支
- 02查看问题关联的分支
- 03从当前分支获取问题信息
安装
复制下面的命令,在终端中运行。
$
npx skills add https:/ / github.com/ nesszer/ linear-cli --skill linear-git安装后在 Claude Code 中输入/linear-git确认已加载。
README 原文English
来自项目 READMEREADME 暂无中文译文,以下为英文原文;中文介绍见上方。
Git Operations
# Checkout branch for issue (creates if needed)
linear-cli g checkout LIN-123
# Show branch name
linear-cli g branch LIN-123
# Create branch without checkout
linear-cli g create LIN-123
# Create GitHub PR from Linear issue
linear-cli g pr LIN-123
linear-cli g pr LIN-123 --draft # Draft PR
linear-cli g pr LIN-123 --base main # Specify base branch
# jj (Jujutsu) - show commits with Linear trailers
linear-cli g commits
Context
# Get issue from current branch
linear-cli context
linear-cli context --output json
Flags
| Flag | Purpose |
|---|---|
--draft | Create draft PR |
--base BRANCH | Base branch |
--output json | JSON output |
评论
支持 Markdown