On 22 Nov 2013, at 20:56, Terpstra Brett wrote:
Sorry if this has been covered, I couldn't find it in the archives:
Is there a way to get the filename/path for a message into an
environment variable for a bundle? Similar to the ${subject.body}
variables?
Two answers:
No: The reason is that even though MailMate knows the path where a given
message should be saved then it might not have happened yet. Saving is
handled by a separate thread.
Yes: The path can be derived from the ${#source} variable which is kind
of an IMAP URL (not quite following the IMAP URL standard).
What are you going to do with the path? If it is with the purpose of
reading the raw file then it might be better just to ask MailMate to
provide the message on stdin (using `input = 'raw'`).
Side note: I'm just getting started on my first bundle. It currently
has one command that lets you grab a message URL with a shortcut key,
which is handy for pasting into nvALT or TaskPaper.
Similar to “View ▸ Copy as Link…”?
More to come, I hope. I got addicted to writing TextMate bundles back
in the early days...
Sounds great. Just what I need even if it exposes the missing features
of the bundle system ;-) Questions are welcome. Eventually it'll force
me to document more features.
--
Benny
_______________________________________________
mailmate mailing list
mailmate@lists.freron.com
http://lists.freron.com/listinfo/mailmate