Gnus development mailing list
 help / color / mirror / Atom feed
From: Trevor Murphy <trevor.m.murphy@gmail.com>
To: ding@gnus.org
Subject: Extend nnimap to request Gmail labels with message headers
Date: Mon, 10 Nov 2014 20:09:20 -0500	[thread overview]
Message-ID: <1415668163-29280-1-git-send-email-trevor.m.murphy@gmail.com> (raw)

This is a proof-of-concept / RFC series of patches.  It may not make sense to
treat these labels as message headers, I just find it suits my workflow pretty
well.

I had to significantly rewrite `nnimap-header-parameters' to incorporate the
option, so please pay special attention to the first patch.  Note that the it
shouldn't change the functionality, it's just a rewrite that makes the later
patches possible.

After that first patch the next two just parse Google's response.  I haven't
extensively tested Google's API, so even though this code works for me and
looks simple, I don't know when it will break.

The net result is that you get X-GM-LABELS exposed as a message header.  The
content is always a parenthesized (possibly empty) list.  Full docs here:
https://developers.google.com/gmail/imap_extensions#access_to_gmail_labels_x-gm-labels

I add this to `gnus-extra-headers' and use it all over my Gmail summary
buffers.

For instance, you can display the labels in summary buffer lines with a user
format function and narrow the buffer to a label with limit-to-extra.

Thoughts?

-- 
Trevor Murphy, ASA, MAAA
GnuPG Key: 0x83881C0A



             reply	other threads:[~2014-11-11  1:09 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-11  1:09 Trevor Murphy [this message]
2014-11-11  1:09 ` [RFC 1/3] Rewrite `nnimap-header-parameters' Trevor Murphy
2014-11-11  1:09 ` [RFC 2/3] Request Gmail labels in IMAP headers Trevor Murphy
2014-11-11  1:09 ` [RFC 3/3] Parse Gmail labels as " Trevor Murphy
2014-11-11  1:18 ` Extend nnimap to request Gmail labels with message headers Ted Zlatanov
2014-11-11  2:19 ` Eric Abrahamsen
2014-11-11  3:29   ` Trevor Murphy
2014-11-11  7:11     ` Eric Abrahamsen
2014-11-14  4:15 ` Trevor Murphy
2015-01-26  4:31 ` Lars Ingebrigtsen
2015-01-26  5:44   ` Trevor Murphy
2015-01-26  7:12     ` Lars Ingebrigtsen
2015-01-26  9:41       ` Lars Ingebrigtsen
2015-01-29 18:13         ` Trevor Murphy
2015-02-04 11:40           ` Ted Zlatanov
2015-02-05  2:38             ` Lars Ingebrigtsen
2015-02-05  4:09               ` Ted Zlatanov
2015-02-05  4:42                 ` Lars Ingebrigtsen
2015-02-05  2:36           ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1415668163-29280-1-git-send-email-trevor.m.murphy@gmail.com \
    --to=trevor.m.murphy@gmail.com \
    --cc=ding@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).