Gnus development mailing list
 help / color / mirror / Atom feed
* New "gnus-search" syntax and interface
@ 2020-11-04 17:15 Eric Abrahamsen
  2020-11-04 18:14 ` Pankaj Jangid
                   ` (5 more replies)
  0 siblings, 6 replies; 65+ messages in thread
From: Eric Abrahamsen @ 2020-11-04 17:15 UTC (permalink / raw)
  To: ding

[Resending via ding as the newsgroup seems to be unresponsive]

Hi all,

For those of you on Emacs master, I just pushed the gnus-search.el
library, which I've been sitting on for a while. It obsoletes nnir.el
(while borrowing some of its code), and uses nnselect to display search
results.

Under default settings, it should do nothing at all, and searches should
behave exactly as before. The nnir.el library has been moved to
lisp/obsolete, so code that requires it should not break, but it is no
longer needed.

If anything breaks for anyone out of the box (though it shouldn't),
please let me know right away!

Past that, the fun stuff comes if you set
`gnus-search-use-parsed-queries' to t. That will enable the "generalized
query syntax", a single search syntax that can be used across any
supported search engine. That means you can mark an imap group and a
maildir group indexed by notmuch (for instance), and issue a single
query against both. The query will be parsed and transformed into
strings that the engines accept, and you'll get the expected results.

It also opens the door to some nice conveniences. You can search by Gnus
mark, for instance. Or issue relative date queries like "since:4d" for
messages in the last four days (no need to remember the IMAP date
format!). Or "limit:20" for just some results. If you use EBDB, I've
already pushed a change so you can auto-complete contact names or email
addresses on keys like "from" or "to" or "cc". I'll propose a similar
addition to BBDB soon.

The syntax is fully documented in the new "Search Queries" section of
the Gnus manual, but basically it looks like this:

(from:bob or from:jane) -to:sam since:2w subject:"sam's surprise party"

Terms can be negated with a minus sign, as above, or with a preceding
"not". Terms can be auto-completed with TAB, or you can leave them
abbreviated so long as they're not ambiguous. So the query above could
be:

(f:bob or f:jane) -t:sam sin:2w su:"sam's surprise party"

You can shut off the parsing and use the native syntax of whatever group
you're searching on a per-engine, per-server, or per-search basis. See
the manual for details.

I hope this is a welcome addition!

Eric


^ permalink raw reply	[flat|nested] 65+ messages in thread

end of thread, other threads:[~2020-12-22 18:10 UTC | newest]

Thread overview: 65+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-04 17:15 New "gnus-search" syntax and interface Eric Abrahamsen
2020-11-04 18:14 ` Pankaj Jangid
2020-11-04 18:45   ` Eric Abrahamsen
2020-11-04 19:32     ` Pankaj Jangid
2020-11-04 19:39     ` Pankaj Jangid
2020-11-04 19:49       ` Eric Abrahamsen
2020-11-05  2:19 ` Eric Abrahamsen
2020-11-05 11:58 ` Adam Sjøgren
2020-11-05 16:04   ` Eric Abrahamsen
2020-11-05 16:14     ` Eric Abrahamsen
2020-11-05 16:41     ` Adam Sjøgren
2020-11-05 17:18       ` Eric Abrahamsen
2020-11-05 17:34         ` Adam Sjøgren
2020-11-06  3:50           ` Eric Abrahamsen
2020-11-06  6:23 ` Jose A. Ortega Ruiz
     [not found]   ` <12MvvhYMQyipeZzkJx1ODwHAD4xQZo6qw1FSX6nvgZAyLZCPkEVFXXGxOQTuxL1zvwZC6BER4jnUFXNgIEjIZA==@protonmail.internalid>
2020-11-07  4:59   ` Eric Abrahamsen
2020-11-08  1:23     ` Jose A. Ortega Ruiz
     [not found]       ` <VEKLrJRKnbVIVztgsX0O5q0i9OwitXf-t5q2hcVN-ZDq0SRE1KS4DIpk7iNeQxIhD1_9AC4DWOdDJsJW2XCMlg==@protonmail.internalid>
2020-11-08  2:38       ` Eric Abrahamsen
2020-11-08  2:51         ` Jose A. Ortega Ruiz
2020-11-08  2:55         ` Andrew Cohen
2020-11-08  2:43     ` Jose A. Ortega Ruiz
2020-11-08  5:03       ` Eric Abrahamsen
2020-11-08  7:16         ` Jose A. Ortega Ruiz
2020-11-12 20:51           ` Eric Abrahamsen
2020-11-13  3:17             ` Jose A. Ortega Ruiz
     [not found]               ` <-NlYHnQ3eprZs5vpzJzwiWpUHjyOUwbkarR4R4m8DK_5ik1XoE8SVsxNfQWJwgUWVIfjwxU5eCbwaWIzwZUJNQ==@protonmail.internalid>
2020-11-13  6:38               ` Eric Abrahamsen
2020-11-13 19:15                 ` Jose A. Ortega Ruiz
2020-11-14  1:02                   ` Eric Abrahamsen
2020-11-13 11:07 ` Eric S Fraga
2020-11-13 12:39   ` Gijs Hillenius
2020-11-13 13:01     ` Eric S Fraga
2020-11-13 16:15       ` Eric Abrahamsen
2020-11-13 16:56         ` Eric S Fraga
2020-11-13 17:21           ` Eric Abrahamsen
2020-11-13 20:06             ` Jose A. Ortega Ruiz
2020-11-16 10:44               ` Eric S Fraga
2020-11-16 15:00               ` Eric S Fraga
2020-11-16 18:47                 ` Eric Abrahamsen
2020-11-17 11:04                   ` Eric S Fraga
2020-11-17 23:58                     ` Eric Abrahamsen
2020-11-18  0:46                       ` Jose A. Ortega Ruiz
2020-11-18 20:40                         ` Eric Abrahamsen
     [not found]                         ` <1x7NOCTHudFuCvB0kEBCGDds7KKAdbu-tZRD41ue36qG8dPBUSj7W9lq7CK5WJwL50cGQKZcom2KMkW_2VZi8Q==@protonmail.internalid>
     [not found]                           ` <871rgqz98k.fsf@ericabrahamsen.net>
2020-11-18 21:05                             ` Jose A. Ortega Ruiz
2020-11-18 21:31                               ` Eric Abrahamsen
2020-11-18  9:21 ` yoctocell
2020-11-18 20:53   ` Eric Abrahamsen
2020-11-19 11:02     ` yoctocell
2020-11-22 12:56     ` yoctocell
2020-11-22 16:31       ` Eric Abrahamsen
     [not found]         ` <86lfel9z1b.fsf@yoctocell.xyz>
2020-11-30  4:40           ` Eric Abrahamsen
2020-11-30  8:17             ` yoctocell
2020-11-30 17:30               ` Eric Abrahamsen
2020-12-01  7:47                 ` yoctocell
2020-12-02  2:16                   ` Eric Abrahamsen
2020-12-02  7:17                     ` yoctocell
2020-12-11  1:39                       ` Eric Abrahamsen
2020-12-11  7:55                         ` yoctocell
2020-12-13 10:18                           ` yoctocell
2020-12-13 11:23                             ` yoctocell
2020-12-13 16:49                               ` Eric Abrahamsen
2020-12-13 21:13                                 ` yoctocell
2020-12-18  4:30                                   ` Eric Abrahamsen
2020-12-18  8:21                                     ` yoctocell
2020-12-22 17:05                                       ` Eric Abrahamsen
2020-12-22 18:10                                         ` yoctocell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).