feat(pr): add pr +comment shortcut #15
Loading…
Reference in New Issue
No description provided.
Delete Branch "wbtiger/gitlink-cli:feat/pr-comment"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
背景
在 review PR #13 时发现,给 PR 添加评论需要先通过 pr +view 获取 issue ID,再用 issue +comment 或原始 API 调用。流程不够直观。
改动
新增
pr +comment命令,作为语法糖简化给 PR 评论的流程:内部自动通过
GET /pulls/{id}获取 PR 对应的 issue ID,再调用/v1/{owner}/{repo}/issues/{id}/journals发送评论。文件清单
测试
go test ./...全部通过--id 14813(pull_request_id)和--id 1(pull_request_number)均正常