From mboxrd@z Thu Jan 1 00:00:00 1970 From: Erik Hetzner Subject: Re: [PATCH] org-attach.el: Fetch attachments from git annex Date: Tue, 05 Jan 2016 17:27:18 -0800 Message-ID: <568c6d77.2983420a.8a565.3478@mx.google.com> References: <568b532e.d111620a.b25a8.ffffbb7c@mx.google.com> <568b5e82.0406430a.a1c6a.0ce9@mx.google.com> Reply-To: Erik Hetzner Mime-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48758) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aGcsl-0000BJ-O8 for emacs-orgmode@gnu.org; Tue, 05 Jan 2016 20:27:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aGcsi-0001g0-Ex for emacs-orgmode@gnu.org; Tue, 05 Jan 2016 20:27:23 -0500 Received: from mail-pa0-x229.google.com ([2607:f8b0:400e:c03::229]:36131) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aGcsi-0001fw-8Y for emacs-orgmode@gnu.org; Tue, 05 Jan 2016 20:27:20 -0500 Received: by mail-pa0-x229.google.com with SMTP id yy13so131566177pab.3 for ; Tue, 05 Jan 2016 17:27:20 -0800 (PST) In-Reply-To: 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: Rasmus Cc: emacs-orgmode@gnu.org Hi Rasmus, On Tue, 05 Jan 2016 01:56:39 -0800, Rasmus wrote: >=20 > Hi Erik, >=20 >=20 > For long prose like this I'd just export the patch (git format-patch) > and attach it to an email like this. But this is also fine... Perhaps > Kyle's method is more pro. Thanks! I=E2=80=99m not sure which seems better either. > [=E2=80=A6] >=20 > This is a good idea. Though really this sounds like something that > should be done by the git annex assistant rather than per application. >=20 > Has Joey spoken for or against automatic fetching of content when > requested? If a user prefers to use git annex assistant or preferred content that shou= ldn=E2=80=99t interfere with this. But to my mind, opening an attachment is a pretty clear indication of the user=E2=80=99s desire to fetch the file from git annex, s= o it would be nice to do it. > > (It would be nice to have Org do the same thing when exporting to HTML = > as well, > > if the git annex file is an image that is being exported as an=20 > embedded image > > link, but I can=E2=80=99t figure out how to do that.) >=20 > A stronger argument for for first figuring out whether it=20 Well, I think it would have been nice, but the =E2=80=9Cpreferred content= =E2=80=9D feature you reference below seems like it could cover most of this. And, while I think = that trying to open an attachment is a pretty clear indication that the user wan= ts to fetch the file from git annex, exporting is much less clear. I=E2=80=99m pr= etty convinced that Kyle is right that git annex support belongs in org-attach, = but not elsewhere. > [=E2=80=A6] >=20 > IMO we should get rid of org-attach-git-annex-cutoff and point to > preferred content: >=20 > http://git-annex.branchable.com/preferred_content/ >=20 > E.g. I might have a small mp3 file. There's no point in storing it with > git rather than git annex. >=20 > When preferred content is set up, I think git annex add will do the > right thing. I=E2=80=99m not certain how preferred content works, but it doesn=E2=80=99t= seem to apply to which content is added to git annex (as opposed to added to the git repo itself), which is what org-attach-git-annex-cutoff does. > Can you ask annex if it's an annexed file? A symlink in an annexed=20 > folder, > to a usb disk that is not attached would pass this test. But the=20 > indication would be wrong. Thanks! I=E2=80=99m going to use Kyle=E2=80=99s suggestion here, to use =3D= git annex find PATH=3D. best, Erik -- Sent from my free software system .