docs(search): add reference to gh help search
This commit is contained in:
parent
254119e498
commit
dd0a0b3045
5 changed files with 13 additions and 18 deletions
|
|
@ -47,8 +47,7 @@ func NewCmdCode(f *cmdutil.Factory, runF func(*CodeOptions) error) *cobra.Comman
|
|||
The results might not match what is seen on %[1]sgithub.com%[1]s, and new features like regex search
|
||||
are not yet available via the GitHub API.
|
||||
|
||||
Note: When using GitHub search syntax to exclude results (e.g. '-language:xml'), you must use
|
||||
a '--' delimiter before the search query to separate it from command flags.
|
||||
For more information on handling search queries containing a hyphen, run %[1]sgh help search-syntax%[1]s.
|
||||
`, "`"),
|
||||
Example: heredoc.Doc(`
|
||||
# Search code matching "react" and "lifecycle"
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ func NewCmdCommits(f *cmdutil.Factory, runF func(*CommitsOptions) error) *cobra.
|
|||
cmd := &cobra.Command{
|
||||
Use: "commits [<query>]",
|
||||
Short: "Search for commits",
|
||||
Long: heredoc.Doc(`
|
||||
Long: heredoc.Docf(`
|
||||
Search for commits on GitHub.
|
||||
|
||||
The command supports constructing queries using the GitHub search syntax,
|
||||
|
|
@ -46,9 +46,8 @@ func NewCmdCommits(f *cmdutil.Factory, runF func(*CommitsOptions) error) *cobra.
|
|||
GitHub search syntax is documented at:
|
||||
<https://docs.github.com/search-github/searching-on-github/searching-commits>
|
||||
|
||||
Note: When using GitHub search syntax to exclude results (e.g. '-user:monalisa'), you must use
|
||||
a '--' delimiter before the search query to separate it from command flags.
|
||||
`),
|
||||
For more information on handling search queries containing a hyphen, run %[1]sgh help search-syntax%[1]s.
|
||||
`, "`"),
|
||||
Example: heredoc.Doc(`
|
||||
# Search commits matching set of keywords "readme" and "typo"
|
||||
$ gh search commits readme typo
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ func NewCmdIssues(f *cmdutil.Factory, runF func(*shared.IssuesOptions) error) *c
|
|||
cmd := &cobra.Command{
|
||||
Use: "issues [<query>]",
|
||||
Short: "Search for issues",
|
||||
Long: heredoc.Doc(`
|
||||
Long: heredoc.Docf(`
|
||||
Search for issues on GitHub.
|
||||
|
||||
The command supports constructing queries using the GitHub search syntax,
|
||||
|
|
@ -35,9 +35,8 @@ func NewCmdIssues(f *cmdutil.Factory, runF func(*shared.IssuesOptions) error) *c
|
|||
GitHub search syntax is documented at:
|
||||
<https://docs.github.com/search-github/searching-on-github/searching-issues-and-pull-requests>
|
||||
|
||||
Note: When using GitHub search syntax to exclude results (e.g. '-label:bug'), you must use
|
||||
a '--' delimiter before the search query to separate it from command flags.
|
||||
`),
|
||||
For more information on handling search queries containing a hyphen, run %[1]sgh help search-syntax%[1]s.
|
||||
`, "`"),
|
||||
Example: heredoc.Doc(`
|
||||
# Search issues matching set of keywords "readme" and "typo"
|
||||
$ gh search issues readme typo
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ func NewCmdPrs(f *cmdutil.Factory, runF func(*shared.IssuesOptions) error) *cobr
|
|||
cmd := &cobra.Command{
|
||||
Use: "prs [<query>]",
|
||||
Short: "Search for pull requests",
|
||||
Long: heredoc.Doc(`
|
||||
Long: heredoc.Docf(`
|
||||
Search for pull requests on GitHub.
|
||||
|
||||
The command supports constructing queries using the GitHub search syntax,
|
||||
|
|
@ -37,9 +37,8 @@ func NewCmdPrs(f *cmdutil.Factory, runF func(*shared.IssuesOptions) error) *cobr
|
|||
GitHub search syntax is documented at:
|
||||
<https://docs.github.com/search-github/searching-on-github/searching-issues-and-pull-requests>
|
||||
|
||||
Note: When using GitHub search syntax to exclude results (e.g. '-label:bug'), you must use
|
||||
a '--' delimiter before the search query to separate it from command flags.
|
||||
`),
|
||||
For more information on handling search queries containing a hyphen, run %[1]sgh help search-syntax%[1]s.
|
||||
`, "`"),
|
||||
Example: heredoc.Doc(`
|
||||
# Search pull requests matching set of keywords "fix" and "bug"
|
||||
$ gh search prs fix bug
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ func NewCmdRepos(f *cmdutil.Factory, runF func(*ReposOptions) error) *cobra.Comm
|
|||
cmd := &cobra.Command{
|
||||
Use: "repos [<query>]",
|
||||
Short: "Search for repositories",
|
||||
Long: heredoc.Doc(`
|
||||
Long: heredoc.Docf(`
|
||||
Search for repositories on GitHub.
|
||||
|
||||
The command supports constructing queries using the GitHub search syntax,
|
||||
|
|
@ -47,9 +47,8 @@ func NewCmdRepos(f *cmdutil.Factory, runF func(*ReposOptions) error) *cobra.Comm
|
|||
GitHub search syntax is documented at:
|
||||
<https://docs.github.com/search-github/searching-on-github/searching-for-repositories>
|
||||
|
||||
Note: When using GitHub search syntax to exclude results (e.g. '-topic:linux'), you must use
|
||||
a '--' delimiter before the search query to separate it from command flags.
|
||||
`),
|
||||
For more information on handling search queries containing a hyphen, run %[1]sgh help search-syntax%[1]s.
|
||||
`, "`"),
|
||||
Example: heredoc.Doc(`
|
||||
# Search repositories matching set of keywords "cli" and "shell"
|
||||
$ gh search repos cli shell
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue