Search code examples
githubpull-request

How do I exclude a PR from search based on its title?


I want to exclude any PR that starts with "fix":

is:pr is:open review:required draft:no -in:title "fix"  

This is the result.

Clearly that doesn't work. But the docs say that you can filter out search terms using a minus. If I search using in:title "fix" I get 5 PRs that all start with fix. This looks like a bug but maybe I'm misreading the docs. I tried using the author filter as well, with worse results.


Solution

  • The docs you link mention "With issue and pull request search terms, you can...". However, title is not a specifically issue or pull request term. You can use NOT (docs) instead:

    is:pr is:open review:required draft:no NOT in:title "fix":