saved searches [Was: Named tags/lables?]
On 04.11.11 09:44, Tim Gray wrote: The smart folders (saved searches) are pretty nice in my opinion and are very fast. Coupled with a labels scheme such as the one you wrote about, you have something that competes with gmail/notmuch/sup without fooling around with IMAP standards or running an email client from within emacs. The labels scheme is something which I too have been waiting for. Many thanks for the work being done. The saved searches puzzle me a bit, though. Done today, they'll be incomplete tomorrow, after more incoming, and therefore not worth preserving, even more so since they are very fast to recreate in complete form. Sorting the ~5% of posts which I keep, into categories has my mailbox count at 991 today; 48 for mutt, 59 for vim, and 310 for a cnc list I'm on. Really good stuff¹ goes into my 300 page extracranial memory - a text file with search tags, now also with vim's folding enabled, so it first presents as a single-page TOC. So, in short, my experience is that information is more valuable if most of it is discarded, and what remains is organised in advance. (Only one variable is added to the discard/keep decision made when reading each post, anyway.) Erik ¹ i.e. personally relevant useful. The file started out as What works for me, and I don't want to have to reinvent this next time I need it. -- I can only reply that I arrived at it by experimenting until I found something that works, and then stopping.- Rick Moen, on luv-main
Re: Named tags/lables?
On Nov 04, 2011 at 05:25 PM +0100, Jostein Berntsen wrote: If you use mu search you can easily save your search to a new search folder by just changing the folder path. Standard mu search: mu find --clearlinks --format=links --linksdir=~/mail/search search term Good idea. I never thought of changing the results folder on the fly.
Re: Named tags/lables?
On Nov 03, 2011 at 03:43 PM -0500, David Champion wrote: If you use X-labels heavily and are comfortable building mutt from source I encourage you to take a look at https://bitbucket.org/dgc/mutt-dgc/qseries and apply at least up to the complete-pattern-y patch. I wouldn't mind trying this out, but I'm a little unclear how to apply the patches. I normally build mutt from the hg sources... Furthermore, what would really add to mutt in my mind is some 'smart folder' capability. Anyone who uses a Mac and is on OS X 10.7 should take a look at the new Mail.app. The smart folders (saved searches) are pretty nice in my opinion and are very fast. Coupled with a labels scheme such as the one you wrote about, you have something that competes with gmail/notmuch/sup without fooling around with IMAP standards or running an email client from within emacs.
Re: Named tags/lables?
On 04.11.11,09:44, Tim Gray wrote: On Nov 03, 2011 at 03:43 PM -0500, David Champion wrote: If you use X-labels heavily and are comfortable building mutt from source I encourage you to take a look at https://bitbucket.org/dgc/mutt-dgc/qseries and apply at least up to the complete-pattern-y patch. I wouldn't mind trying this out, but I'm a little unclear how to apply the patches. I normally build mutt from the hg sources... Furthermore, what would really add to mutt in my mind is some 'smart folder' capability. Anyone who uses a Mac and is on OS X 10.7 should take a look at the new Mail.app. The smart folders (saved searches) are pretty nice in my opinion and are very fast. Coupled with a labels scheme such as the one you wrote about, you have something that competes with gmail/notmuch/sup without fooling around with IMAP standards or running an email client from within emacs. If you use mu search you can easily save your search to a new search folder by just changing the folder path. Standard mu search: mu find --clearlinks --format=links --linksdir=~/mail/search search term Jostein
Re: Named tags/lables?
* On 04 Nov 2011, Tim Gray wrote: On Nov 03, 2011 at 03:43 PM -0500, David Champion wrote: If you use X-labels heavily and are comfortable building mutt from source I encourage you to take a look at https://bitbucket.org/dgc/mutt-dgc/qseries and apply at least up to the complete-pattern-y patch. I wouldn't mind trying this out, but I'm a little unclear how to apply the patches. I normally build mutt from the hg sources... Example: hg qclone https://bitbucket.org/dgc/mutt-dgc mutt-labels cd mutt-labels hg qpush complete-pattern-y hg up HEAD ./prepare --prefix=... etc Furthermore, what would really add to mutt in my mind is some 'smart folder' capability. Anyone who uses a Mac and is on OS X 10.7 should take a look at the new Mail.app. The smart folders (saved searches) are pretty nice in my opinion and are very fast. Coupled with a labels scheme such as the one you wrote about, you have something that competes with gmail/notmuch/sup without fooling around with IMAP standards or running an email client from within emacs. That could be nice but it's a long way beyond what we have the ability to do now. Mutt's current design allows it to open only one mailbox at a time, though you could work around this if you don't need full interactive access to the mailbox. And it doesn't currently have any external metadata storage other than header caches, so there's no easy searching for tags across a multitude of mailboxes (I have over 4500) that also indexes down to the individual message location. Other MUAs have tighter control of this by rigidly defining their internal message store format, but mutt is committed to using open mailstores (mbox, maildir, mh, etc) directly, not just permitting imports from them. These would be substantial changes to implement. :/ -- David Champion • d...@uchicago.edu • IT Services • University of Chicago
Named tags/lables?
Is there any facility similar to Gmail's named tags (other than folders) for mutt? I'd like to be able to add (multiple) labels to a given message, possible automatically (procmail, some imap tool, mutt folder hooks), have mutt be aware of defined labels, and be able to quickly filter messages by labels (including and/or/not Boolean logic). That and/or a global search tool (and yes I'm aware that several of these exist) would be great adds for mutt. If there are existing tricks / tools that accomplish same, I'd appreciate seeing them. -- Dr. Ed Morbius Chief Scientist / Philologist / Robot Wrangler / Powerplant Operator Krell Power Systems Unlimited
Re: Named tags/lables?
On 03Nov2011 10:05, Edward Morbius dredmorb...@gmail.com wrote: | Is there any facility similar to Gmail's named tags (other than | folders) for mutt? | | I'd like to be able to add (multiple) labels to a given message, | possible automatically (procmail, some imap tool, mutt folder hooks), | have mutt be aware of defined labels, and be able to quickly filter | messages by labels (including and/or/not Boolean logic). The X-Label: header is the usual convention for this in mutt-land. Mutts which are aware of it have a ~y operator in the pattern syntax (see the PATTERNS heading in man muttrc), but otherwise a more cumbersome header check on X-Label: blah with be needed in patterns. I insert stuff into the X-Label header with procmail at filing time, as with the formail line in this procmail rule: # cats/home: zsh Zsh-Users zsh-us...@zsh.org :0 * ^(to|cc|bcc):.*\(zsh-us...@zsh.org)\ { DEFAULT=/dev/null :0c:.lock-global-procmail { LOG=`datecode` `email-summary-line 21 || :` :0whf | formail -f -A 'X-Cats2Procmailrc-Rule: cats/home: zsh Zsh-Users zsh-us...@zsh.org' :0whf | formail -f -A 'X-Label: Zsh-Users' :0 /home/cameron/mail/zsh/ } } (Yes, I write procmail rules using a program. The source for the above rule is in its opening comment:-) Anyway, that inserts an X-Label into the message headers before filing. The X-Labels are displayed in my mutt index using the %y format: set index_format=%D %-15.15F %S %?M?(%M) ?%?H?[%H] ?%s% %y %4c I haven't tried using multiple X-Labels (which would probably be one header with multiple labels, but maybe not...). | That and/or a global search tool (and yes I'm aware that several of | these exist) would be great adds for mutt. I use mairix myself, via a simple shell wrapper to make the invocation easy. I have not yet investigated searching X-Label headers with it; currently I mostly use X-Labels to identify multiple lists filed in a single folder. | If there are existing tricks / tools that accomplish same, I'd | appreciate seeing them. Me too. Cheers, -- Cameron Simpson c...@zip.com.au DoD#743 http://www.cskk.ezoshosting.com/cs/ The most annoying thing about being without my files after our disc crash was discovering once again how widespread BLINK was on the web.
Re: Named tags/lables?
* On 03 Nov 2011, Cameron Simpson wrote: On 03Nov2011 10:05, Edward Morbius dredmorb...@gmail.com wrote: | Is there any facility similar to Gmail's named tags (other than | folders) for mutt? | | I'd like to be able to add (multiple) labels to a given message, | possible automatically (procmail, some imap tool, mutt folder hooks), | have mutt be aware of defined labels, and be able to quickly filter | messages by labels (including and/or/not Boolean logic). The X-Label: header is the usual convention for this in mutt-land. ... [good information elided] ... I wrote the X-Label code for mutt 11 years ago but recently have been wishing for more capability and better integration with other keywording standards and conventions. (X-Label was invented just for mutt because there were no plausible conventions or standards yet.) If you use X-labels heavily and are comfortable building mutt from source I encourage you to take a look at https://bitbucket.org/dgc/mutt-dgc/qseries and apply at least up to the complete-pattern-y patch. This is the direction that I'd like mutt mainline to go in the future but I'm not comfortable pushing it until it's had more field testing. (That said, I've been using it since April without concern.) Here's the full mercurial commit log for these patches. The xlabel_ext patch is actually quite old, but the others are new this year. --- patch: hashwalk Add reentrant hash_walk() function for iterating down a hash table. --- patch: dgc.xlabel_ext Adds capability to edit x-labels inside mutt, and to sort by label. --- patch: xlabel_complete Adds label completion. A global label hash is added, to which labels are added as they're parsed from a mailbox file or edited manually by the user. Reference counts are kept in the hash table so that unused labels are removed from available completions. Completion is available in the label editor only, but it may be feasible to add for search expressions if the preceding text ends with '~y'. --- patch: keywords Unify label/keyword handling. Since x-labels were added to mutt in 2000, a number of other approaches to what we now call 'tagging' have also emerged. One of them was even made standard in RFC 2822. This update unifies the handling of all these strategies. We start by changing mutt's internal keyword storage from a single string which may contain whitespace to a list of discrete keywords. This has advantages for keyword completion as well as for portabilty among varying standards for keyword storage. This may represent a significant change for existing mutt users who have set x-labels containing spaces, and should be regarded with suspicion. The advantages are significant, though. Next we allow mutt to parse keywords into this internal list from any of the following headers: X-Label (freeform), X-Keywords (space-delimited), X -Mozilla-Keys (space-delimited), and Keywords (RFC 2822, comma-space- delimited). Mutt remembers which headers it sourced keywords from, and will rewrite those headers when saving messages for compatibility with the mailer of origin. (X-Label was specified as freeform text by mutt, its only known implementation. X-Labels have been used both as a 'tagging' device, probably with space delimiting, and as a 'memo' field, where space-delimited parsing would ruin the semantics of the memo. By default mutt will not split X-Labels at all. Set $xlabel_delimiter if your needs vary.) Finally we add the save_keywords boolean, which defaults to FALSE. When true, this boolean causes mutt to always save all keywords to the Keywords: header in addition to whatever origin headers were retained for compatibility. Overall this represents convergence path for all competing labelling/tagging/kewording systems toward one that is specified by RFC. --- patch: complete-pattern-y Permit tab completion of pattern expressions with ~y (labels). --- -- David Champion • d...@uchicago.edu • IT Services • University of Chicago
Re: Named tags/lables?
On 03.11.11,10:05, Edward Morbius wrote: Is there any facility similar to Gmail's named tags (other than folders) for mutt? I'd like to be able to add (multiple) labels to a given message, possible automatically (procmail, some imap tool, mutt folder hooks), have mutt be aware of defined labels, and be able to quickly filter messages by labels (including and/or/not Boolean logic). That and/or a global search tool (and yes I'm aware that several of these exist) would be great adds for mutt. If there are existing tricks / tools that accomplish same, I'd appreciate seeing them. I use the editlabel scriptand the setup at this site: http://blitiri.com.ar/p/other/mutt-labels/ This adds labels to the X-Label field, and it is easy to limit the view to a specific tag. For global search you can use the mu search tool which can search in the X-label field over several mailboxes and return the result promptly: http://www.djcbsoftware.nl/code/mu/ Jostein
Re: Named tags/lables?
Hi David! On Do, 03 Nov 2011, David Champion wrote: * On 03 Nov 2011, Cameron Simpson wrote: On 03Nov2011 10:05, Edward Morbius dredmorb...@gmail.com wrote: | Is there any facility similar to Gmail's named tags (other than | folders) for mutt? | | I'd like to be able to add (multiple) labels to a given message, | possible automatically (procmail, some imap tool, mutt folder hooks), | have mutt be aware of defined labels, and be able to quickly filter | messages by labels (including and/or/not Boolean logic). The X-Label: header is the usual convention for this in mutt-land. ... [good information elided] ... I wrote the X-Label code for mutt 11 years ago but recently have been wishing for more capability and better integration with other keywording standards and conventions. (X-Label was invented just for mutt because there were no plausible conventions or standards yet.) If you use X-labels heavily and are comfortable building mutt from source I encourage you to take a look at https://bitbucket.org/dgc/mutt-dgc/qseries and apply at least up to the complete-pattern-y patch. This is the direction that I'd like mutt mainline to go in the future but I'm not comfortable pushing it until it's had more field testing. (That said, I've been using it since April without concern.) Here's the full mercurial commit log for these patches. The xlabel_ext patch is actually quite old, but the others are new this year. --- patch: hashwalk Add reentrant hash_walk() function for iterating down a hash table. --- patch: dgc.xlabel_ext Adds capability to edit x-labels inside mutt, and to sort by label. --- patch: xlabel_complete Adds label completion. A global label hash is added, to which labels are added as they're parsed from a mailbox file or edited manually by the user. Reference counts are kept in the hash table so that unused labels are removed from available completions. Completion is available in the label editor only, but it may be feasible to add for search expressions if the preceding text ends with '~y'. --- patch: keywords Unify label/keyword handling. Since x-labels were added to mutt in 2000, a number of other approaches to what we now call 'tagging' have also emerged. One of them was even made standard in RFC 2822. This update unifies the handling of all these strategies. We start by changing mutt's internal keyword storage from a single string which may contain whitespace to a list of discrete keywords. This has advantages for keyword completion as well as for portabilty among varying standards for keyword storage. This may represent a significant change for existing mutt users who have set x-labels containing spaces, and should be regarded with suspicion. The advantages are significant, though. Next we allow mutt to parse keywords into this internal list from any of the following headers: X-Label (freeform), X-Keywords (space-delimited), X -Mozilla-Keys (space-delimited), and Keywords (RFC 2822, comma-space- delimited). Mutt remembers which headers it sourced keywords from, and will rewrite those headers when saving messages for compatibility with the mailer of origin. (X-Label was specified as freeform text by mutt, its only known implementation. X-Labels have been used both as a 'tagging' device, probably with space delimiting, and as a 'memo' field, where space-delimited parsing would ruin the semantics of the memo. By default mutt will not split X-Labels at all. Set $xlabel_delimiter if your needs vary.) Finally we add the save_keywords boolean, which defaults to FALSE. When true, this boolean causes mutt to always save all keywords to the Keywords: header in addition to whatever origin headers were retained for compatibility. Overall this represents convergence path for all competing labelling/tagging/kewording systems toward one that is specified by RFC. --- patch: complete-pattern-y Permit tab completion of pattern expressions with ~y (labels). --- Wow, this really looks interesting. Thanks for sharing. Hope something like this makes it into mutt soon. regards, Christian