[prev in list] [next in list] [prev in thread] [next in thread] 

List:       mutt-users
Subject:    Re: How can i see the message ID of a message
From:       David Champion <dgc () bikeshed ! us>
Date:       2015-06-19 22:02:16
Message-ID: 20150619220216.GD1417 () scurvy ! bikeshed ! us
[Download RAW message or body]

* On 19 Jun 2015, Michael Tatge wrote: 
> * On Fri, Jun 19, 2015 06:29PM +0200 I (tatgeml@gmail.com) muttered:
> > * On Fri, Jun 19, 2015 02:56PM +0200 ybaumes@gmail.com (ybaumes@gmail.com) \
> > muttered:
> > > Is there a key shortcut in the index/pager to display the MessageID of the \
> > > current email?

Another approach.  I have 4 different versions of my index_format,
depending on what I want to see (and how much), what kind of window I'm
in, etc.  I have a key binding ("Y") that toggles through the list.  You
could do the same with index_format or status_format to display only the
message-id.

Here's my recipe exactly as I use it.  I've replaced the actual values
of the index_format with "INDEX_YY" because my index_formats are very
long and don't work in a regular mutt build, and I don't want to confuse
the issue by displaying them here.  Just substitute your preferences
there.  

macro index =y0 "<enter-command>set \
index_format='INDEX_Y0'<enter><enter-command>macro index Y '=y1'<enter>" macro index \
=y1 "<enter-command>set index_format='INDEX_Y1'<enter><enter-command>macro index Y \
'=y2'<enter>" macro index =y2 "<enter-command>set \
index_format='INDEX_Y2'<enter><enter-command>macro index Y '=y3'<enter>" macro index \
=y3 "<enter-command>set index_format='INDEX_Y3'<enter><enter-command>macro index Y \
'=y0'<enter>" push =y0

If you only wanted two toggle settings:

macro index =y0 "<enter-command>set \
index_format='INDEX_Y0'<enter><enter-command>macro index Y '=y1'<enter>" macro index \
=y1 "<enter-command>set index_format='INDEX_Y1'<enter><enter-command>macro index Y \
'=y0'<enter>" push =y0

The "push =y0" is used instead of setting $index_format directly, so as
to queue up the next item in the list.

So if you used this formula in pager, you could have a toggle that puts
the message-id in the status bar, then when pressed again, removes it.
(%i represents the message-id).

-- 
David Champion • dgc@bikeshed.us


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic