emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Martin Butz <butz@sym.net>
To: emacs-orgmode@gnu.org
Subject: org-mode and claws
Date: Wed, 13 Oct 2010 21:16:15 +0200	[thread overview]
Message-ID: <4CB6057F.3080808@sym.net> (raw)

Hello to All,

I'm using org-mode since a couple of months. I would like to be able to
link to emails from within org-files and I am wondering whether this is
possible using claws-mail. I have googled a few hours but was only able
to solve the problem partly based on a solution integrating mutt [1].

As I do not know very much about lisp - besides extending my .emacs
with snippets I have collected over the time - my adaption is amateurish
and - which is worse - does not work as desired.

I added to my .emacs:

-------------------------8<---------------------------------------------
(defun open-mail-in-claws (message)
   "Open a mail message in Claws.
Message can be specified either by a path pointing inside a
Maildir by Message-ID."
   (interactive "Message-ID: ")
   (shell-command
    (format "claws-mail --select \"%s<%s>\""
					 (substitute-in-file-name
"$HOME/.claws-mail/imapcache/mail.sym.net/butz@sym.net/INBOX/")message)))

;; add support for "claws:ID" links
(org-add-link-type "claws" 'open-mail-in-claws)
-------------------------8<---------------------------------------------

The script has a major problem (besides some more or less grave
restrictions): calling the open-mail-in-claws function makes the buffer
from which I call the script unusable; probably because I do not call
claws in the background (or whatever).

Can anybody give a hint, how this could be done in a better way. Or has
anybody a working solution to open mails in claws-mail from within
org-mode?

Thanks and cheers
Martin

[1]
http://upsilon.cc/~zack/blog/posts/2010/02/integrating_Mutt_with_Org-mode/
-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
sym.net  ||  butz & siefer gbr  ||  50670 koeln  ||  hansaring 78
phone +49(0)221/3762591 -  twitter.com/symnet  - mail butz@sym.net
~~~~~~~~~~~~~~~~~~ www.sym.net | www.moodalis.de ~~~~~~~~~~~~~~~~

                 reply	other threads:[~2010-10-13 19:16 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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

  List information: https://www.orgmode.org/

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

  git send-email \
    --in-reply-to=4CB6057F.3080808@sym.net \
    --to=butz@sym.net \
    --cc=emacs-orgmode@gnu.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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).