From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: [RFC] [patch] open/delete attachment with inherited directory Date: Tue, 17 Dec 2013 18:34:54 +0100 Message-ID: <87sitr8jpd.fsf@gmail.com> References: <874n69fkxc.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:43999) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VsyXc-0001UA-OU for emacs-orgmode@gnu.org; Tue, 17 Dec 2013 12:34:53 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VsyXS-0002dk-FG for emacs-orgmode@gnu.org; Tue, 17 Dec 2013 12:34:44 -0500 Received: from mail-ee0-x229.google.com ([2a00:1450:4013:c00::229]:59540) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VsyXS-0002de-8q for emacs-orgmode@gnu.org; Tue, 17 Dec 2013 12:34:34 -0500 Received: by mail-ee0-f41.google.com with SMTP id t10so3064618eei.0 for ; Tue, 17 Dec 2013 09:34:33 -0800 (PST) Received: from selenimh ([91.224.148.150]) by mx.google.com with ESMTPSA id 1sm54894744eeg.4.2013.12.17.09.34.31 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 Dec 2013 09:34:32 -0800 (PST) In-Reply-To: <874n69fkxc.fsf@gmail.com> (Aaron Ecay's message of "Mon, 16 Dec 2013 00:02:07 -0500") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Hello, Aaron Ecay writes: > I have some org files where each headline corresponds to an entry in a > bibliography. The headlines each have attached to them a pdf file of > the corresponding document. The attachment directory is set as a > file-level property and inherited by the children (this is so that I can > access the files easily also outside of org). > > In the current implementation of org-attach-{open,delete-one}, I am > prompted to choose among all files in the attachment directory (i.e. all > the pdfs of entries in the bibliography), not just the (usually single) > file attached to the headline at point. I think the latter behavior > makes more sense. The attached (heh) patch implements this change. Are > there any comments? Thanks for the patch. I see one major problem, though. Org attach doesn't require to list files attached to the entry (see `org-attach-file-list-property'). Therefore, `org-entry-get-multivalued-property' could return nil even though there are attached files. Regards, -- Nicolas Goaziou