github cli- grep用于通过拉动请求主体中的短语过滤?
我正在使用GitHub CLI工具,其中包括一个命令GH PR列表
,该工具可让您查看所有打开的拉请请求。
问题是我只看到他们的标题列表,并且有一个单独的命令gh pr视图[额外信息]
实际上允许您查看body
。
我正在搜索身体中具有一定短语的拉请请求,因此gh pr列表| GREP“ Hello”
是行不通的,因为它只会在标题中使用“ Hello”
提供拉动请求,而不一定是主体。
我将如何解决这个问题,而Github CLI中是否有任何可能对我有帮助的捷径?
I’m using the Github CLI tool, which includes a command gh pr list
that allows you to see all the open pull requests.
The issue is that I only see a list of their titles and there’s a separate command gh pr view [extra info]
that actually allows you to see the body
.
I’m searching for pull requests that have a certain phrase in the BODY so gh pr list | grep “hello”
wouldn’t work because it only gives me pull requests with “hello”
in the header, and not necessarily the body.
How might I go about approaching this problem and are there any shortcuts in the github cli that might help me?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
sicne
gh pr List
,例如
gh pr view
,确实从相同的选项-json< fields> gt;
(带有指定字段的输出JSON),您可以使用:这将为您的特定消息抓取,并且仍然可以为您提供一个可以与
gh pr View
一起使用的ID。Sicne
gh pr list
, likegh pr view
, does inherit from the same option--json <fields>
(Output JSON with the specified fields), you can use:That would grep for your specific message, and still give you an ID that you can use with
gh pr view
.