xapian: Allow boolean search without capitalization, allow wildcards.
authorRicardo Wurmus <rekado@elephly.net>
Sun, 10 May 2020 06:30:09 +0000 (08:30 +0200)
committerRicardo Wurmus <rekado@elephly.net>
Sun, 10 May 2020 06:30:09 +0000 (08:30 +0200)
mumi/xapian.scm

index cc5997d350fc07f47ea9a3b30ace9700b12c6e79..2723615a7ed46e52befbec86e44766ae73c154d4 100644 (file)
@@ -201,7 +201,12 @@ messages and index their contents in the Xapian database at DBPATH."
               prefixes)
     (QueryParser-add-rangeprocessor queryparser date-range-processor)
     (QueryParser-add-rangeprocessor queryparser mdate-range-processor)
-    (let ((query (QueryParser-parse-query queryparser querystring)))
+    (let ((query (QueryParser-parse-query queryparser querystring
+                                          (logior (QueryParser-FLAG-BOOLEAN)
+                                                  (QueryParser-FLAG-PHRASE)
+                                                  (QueryParser-FLAG-LOVEHATE)
+                                                  (QueryParser-FLAG-BOOLEAN-ANY-CASE)
+                                                  (QueryParser-FLAG-WILDCARD)))))
       (delete-QueryParser queryparser)
       query)))