Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 18413431FC9 for ; Fri, 24 Oct 2014 08:46:50 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.699 X-Spam-Level: X-Spam-Status: No, score=-0.699 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_LOW=-0.7, UNPARSEABLE_RELAY=0.001] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JZRFZp87o4Jx for ; Fri, 24 Oct 2014 08:46:42 -0700 (PDT) Received: from mail-wi0-f181.google.com (mail-wi0-f181.google.com [209.85.212.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id DF6EB431FBD for ; Fri, 24 Oct 2014 08:46:41 -0700 (PDT) Received: by mail-wi0-f181.google.com with SMTP id n3so1619776wiv.2 for ; Fri, 24 Oct 2014 08:46:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:to:cc:subject:in-reply-to:references:user-agent :from:date:message-id:mime-version:content-type; bh=iUFDbwiicY7wm/YkWz7fU5GEfJDvz1zkEvasMFD0ilY=; b=Vy8zhOCWBiWGyTJ0Q4ayJ+wTjza3WC00LYZAaHtWfdaphB2Ig0/1/JWRb2x38WiJGo Pr9p6jBQf/en4YZ05KkAQ7OdB0AQcYtjAk/2yns8J7R3LbV3/0cwqPnnSpyPPyvSjMGt 60ye8ZiURhbBIsz3fYf5hxDlWjE7P11fCycmDXWWKpvejibuaDvmSz1ydJzXexwP75sD xANMm/1aI+GdnAmpTNFNA+6Ohp3cU3t8yK8fpsijB0ngbYJqDUtaN9tBtISUrMin5oEs lLwTIk0PQ8uB9MKvCUsex9NaxRKVJUuJH8fPfGwAgvco0wehruL4PNastjXCRPnjEbWa /QSg== X-Gm-Message-State: ALoCoQk5HekSgYdb0kAeZGQjF1h5sMiKFGWIXCwngucYUCMvri4+5zMUxfu4al28A4zV3h4PWM/p X-Received: by 10.194.134.200 with SMTP id pm8mr3030545wjb.136.1414165599314; Fri, 24 Oct 2014 08:46:39 -0700 (PDT) Received: from disaster-area.hh.sledj.net ([2a01:348:1a2:1:ea39:35ff:fe2c:a227]) by mx.google.com with ESMTPSA id t16sm6016927wjr.44.2014.10.24.08.46.38 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 24 Oct 2014 08:46:38 -0700 (PDT) Received: from localhost (30000@localhost [local]); by localhost (OpenSMTPD) with ESMTPA id 30f69b8a; Fri, 24 Oct 2014 15:46:37 +0000 (UTC) To: Eric Abrahamsen , emacs-orgmode@gnu.org Subject: Re: [O] how to put into a journal info about the email sent In-Reply-To: <87ppdhh3rh.fsf@ericabrahamsen.net> References: <87ppdhh3rh.fsf@ericabrahamsen.net> User-Agent: Notmuch/0.18.1 (http://notmuchmail.org) Emacs/24.3.1 (x86_64-apple-darwin14.0.0) From: David Edmondson Date: Fri, 24 Oct 2014 16:46:36 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain Cc: notmuch@notmuchmail.org X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Oct 2014 15:46:50 -0000 On Fri, Oct 24 2014, Eric Abrahamsen wrote: > David Belohrad writes: > >> Dear All, >> >> i'm using org. And I'm using notmuch (that's why I address both mailing >> lists). Now, writing an email in everyday bussiness requires a >> non-significant time of your workhours. So I'd like to have this event >> in my org agenda. So any time I send some email with a given subject, >> I'd like to 'automatically' entry the information about it into >> e.g. sentmails.org in form of a diary entry, with appropriate tag. > > I do something like this in Gnorb, which I'd recommend you use except > it's mostly Gnus specific. > > I do it in two parts, but you could do it in one. Basically I add a > function to the `message-header-hook' (which ensures that all the > message headers have been generated properly). Does `message-generate-headers-first' not do what you want for this specific part? > Obviously the downside is that, without a "Gcc:" header, org can't > actually make a real link to the message. It doesn't know where it's > going to be. However if you know that all your sent messages can be > reached with a link that looks like "notmuch:id#Message-id", then you > can make that yourself in your org capture template with something like As you suggest, know the message-id should be good enough to generate a notmuch link, though you may have to wait for the notmuch index to be updated for the link to be valid.