Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add search syntax for operators and phrases #11411

Merged
merged 1 commit into from
Jul 27, 2019
Merged

Conversation

Gargron
Copy link
Member

@Gargron Gargron commented Jul 26, 2019

Supports syntax like:

  • Operators, like +foo (AND) and -bar (NOT)
  • Phrases, like "hello world"
  • Prefixes, like foo:"hello world" (currently unused)

It does change the default of treating all words as joined by AND, so "quick fox" will include items that only contain "fox" and only contain "quick" as well (although items containing "quick fox" will score higher, like before).

The new phrase syntax allows to search for an exact sequence of words instead.

Included is also a small change that allows circumventing the URL resolving logic to use only the search even when a URL is given, when the resolve param is set to false. I believe that's how it should have been all along.

@Gargron Gargron merged commit b9fbcbf into master Jul 27, 2019
@ykzts ykzts deleted the feature-search-syntax branch August 7, 2019 15:11
hiyuki2578 pushed a commit to ProjectMyosotis/mastodon that referenced this pull request Oct 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants