]> git.notmuchmail.org Git - notmuch/blobdiff - lib/database.cc
add property: query prefix to search for specific properties
[notmuch] / lib / database.cc
index 33e22d86eae541668b6a896d1ae11fbde732dec0..392e8b2869842130e1372b52d5d9329d0151577e 100644 (file)
@@ -97,6 +97,9 @@ typedef struct {
  *                     STRING is the name of a file within that
  *                     directory for this mail message.
  *
+ *      property:       Has a property with key=value
+ *                 FIXME: if no = is present, should match on any value
+ *
  *    A mail document also has four values:
  *
  *     TIMESTAMP:      The time_t value corresponding to the message's
@@ -251,7 +254,6 @@ static prefix_t BOOLEAN_PREFIX_INTERNAL[] = {
     { "directory",             "XDIRECTORY" },
     { "file-direntry",         "XFDIRENTRY" },
     { "directory-direntry",    "XDDIRENTRY" },
-    { "property",               "XPROPERTY"  },
 };
 
 static prefix_t BOOLEAN_PREFIX_EXTERNAL[] = {
@@ -260,6 +262,7 @@ static prefix_t BOOLEAN_PREFIX_EXTERNAL[] = {
     { "is",                    "K" },
     { "id",                    "Q" },
     { "path",                  "P" },
+    { "property",              "XPROPERTY" },
     /*
      * Unconditionally add ':' to reduce potential ambiguity with
      * overlapping prefixes and/or terms that start with capital