@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Document the Ferret "=" operator and improve related documentation

Summary:
Depends on D19529. See PHI778.

- Document the "name" constraint as deprecated. All callers are likely better served by the "query" constraint.
- Guide users toward the "query" constraint a little better.
- Document the `=` syntax.

Test Plan: Read various new documentation.

Reviewers: amckinley

Reviewed By: amckinley

Differential Revision: https://secure.phabricator.com/D19531

+20 -2
+7 -1
src/applications/project/query/PhabricatorProjectSearchEngine.php
··· 22 22 return array( 23 23 id(new PhabricatorSearchTextField()) 24 24 ->setLabel(pht('Name')) 25 - ->setKey('name'), 25 + ->setKey('name') 26 + ->setDescription( 27 + pht( 28 + '(Deprecated.) Search for projects with a given name or '. 29 + 'hashtag using tokenizer/datasource query matching rules. This '. 30 + 'is deprecated in favor of the more powerful "query" '. 31 + 'constraint.')), 26 32 id(new PhabricatorSearchStringListField()) 27 33 ->setLabel(pht('Slugs')) 28 34 ->setIsHidden(true)
+4 -1
src/applications/search/engineextension/PhabricatorFerretSearchEngineExtension.php
··· 57 57 $fields[] = id(new PhabricatorSearchTextField()) 58 58 ->setKey('query') 59 59 ->setLabel(pht('Query')) 60 - ->setDescription(pht('Fulltext search.')); 60 + ->setDescription( 61 + pht( 62 + 'Find objects matching a fulltext search query. See '. 63 + '"Search User Guide" in the documentation for details.')); 61 64 62 65 return $fields; 63 66 }
+9
src/docs/user/userguide/search.diviner
··· 138 138 - Field search with `title:platypus`. 139 139 - Filtering out matches with `-platypus`. 140 140 - Quoted terms with `"platypus attorney"`. 141 + - Matching entire fields with `=platypus`. 141 142 - Combining features with `title:~"platypus attorney"`. 142 143 143 144 See below for more detail. ··· 173 174 **Filtering Matches**: You can remove documents which match certain terms from 174 175 the result set with `-`. For example: `platypus -mammal`. Documents which match 175 176 negated terms will be filtered out of the result set. 177 + 178 + **Matching Entire Fields**: If you know the exact name of an object and want 179 + to find only that object, you can use the `=` operator. A query like 180 + `title:"warp drive"` will find a document titled "Warp Drive", but will also 181 + find documents with longer titles, like "Not a Warp Drive". The `=` operator 182 + requires that the entire field match the query exactly, so //only// documents 183 + exactly titled "Warp Drive" will be matched by the query (but note that the 184 + query is still case insensitive).