From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id 8JM7LJ6nW2HPHgAAgWs5BA (envelope-from ) for ; Tue, 05 Oct 2021 03:17:18 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id YOfMJ56nW2GbKQAAbx9fmQ (envelope-from ) for ; Tue, 05 Oct 2021 01:17:18 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id D954C144FE for ; Tue, 5 Oct 2021 03:17:17 +0200 (CEST) Received: from localhost ([::1]:60892 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mXZ51-00048X-G3 for larch@yhetil.org; Mon, 04 Oct 2021 21:17:15 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34024) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mXYu5-0007Yv-Ok for emacs-orgmode@gnu.org; Mon, 04 Oct 2021 21:05:58 -0400 Received: from mail-wm1-x330.google.com ([2a00:1450:4864:20::330]:39457) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mXYu2-00049v-MG for emacs-orgmode@gnu.org; Mon, 04 Oct 2021 21:05:57 -0400 Received: by mail-wm1-x330.google.com with SMTP id b136-20020a1c808e000000b0030d60716239so1105467wmd.4 for ; Mon, 04 Oct 2021 18:05:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vicarious-living-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=UBDB9XeIVr98motYInGkBXWIJT2njKq3w+cArcgOTEM=; b=I0uJBUiftQqM0uc2YCL7zNPeBO3yo+pjo2sUuusT/KjFvBYdD9RT/y1EXrL7i3OTVI DsRE0emVNpi7y5RoDRqJUUtahs/AJOYvRxiVu7TXq1y9P6Nji1YwEmGztVJgQ2EdY9we wZZzXMrsLictV8Vyvc2L80Wks/cRcwpAqBWsxHC9PbO+5+B5Sz7tCkyREhjd8qmYw7+A SHth4W5nziTy2RbckbWgcZwh/CtbJvAQyPaUJetbiUTMB6CRKvOUNqCDxPq/p0uCnY9P uaBdR1iU56uKL1u16sGIKY6ClTvQH4uyItwQwZrSrAnBCmsIo5zs8+8cMPAeKUQokKCv zoTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=UBDB9XeIVr98motYInGkBXWIJT2njKq3w+cArcgOTEM=; b=JctkpqneQi3/2ZcfRlXFgsnhj0AICeJGt10m2yRfUWAvxqTbY0y+Cgq5iozz7/8omH PaCLumg9t85LeWUpz7WPRdeRFo39FByXb4UEZro5KmY5SQ+Mp+a8B0aY+nnuqLu3tXzw 6iiVn0sMxw2aXX2/AFsRp0RvVb+5Jp/OOSKLa3jTMcnh40qEG+GxJNWHuUoRFqsBAWE6 4NE9xV9beX6FZqSbIuUV/z2e0GZ20QT9TV16pBJi0nSSVGzSqcse5ruJFzz/6eHJKTro h4TD44hlmEgrb8Xb1XFhmAKwlh5HoXl7wMhuJvDBF5cO4nnEYNRxcBnQ9Wt26lqVnVMH SV1g== X-Gm-Message-State: AOAM532QkpF+27eiMZI+/zwA5/I1bqLOAsbIsVLFk3qkjP5JTtSI2zX2 14hAramKb3v+r50f3Tp0VSjLQIrqcZyb+Dr4KsUZJA== X-Google-Smtp-Source: ABdhPJzmLFFAMR4VdAFbX83RvuN3+SJtQTpHltvNEKcYFoz9UrrBfqsz6k08B9lE6df86XsZy7+xYyIU33jj8Q/as+s= X-Received: by 2002:a1c:3b86:: with SMTP id i128mr284834wma.132.1633395952282; Mon, 04 Oct 2021 18:05:52 -0700 (PDT) MIME-Version: 1.0 References: <981938.1630590273@apollo2.minshall.org> <87czpqjqvw.fsf@localhost> In-Reply-To: From: Ryan Scott Date: Mon, 4 Oct 2021 18:05:41 -0700 Message-ID: Subject: Re: [PATCH] Re: New source block results option for attaching file to node To: numbchild@gmail.com Content-Type: multipart/alternative; boundary="00000000000083835605cd90a1cf" Received-SPF: none client-ip=2a00:1450:4864:20::330; envelope-from=ryan@vicarious-living.com; helo=mail-wm1-x330.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Greg Minshall , emacs-orgmode@gnu.org, Ihor Radchenko , Timothy Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1633396638; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=UBDB9XeIVr98motYInGkBXWIJT2njKq3w+cArcgOTEM=; b=b/KJt20BufwQihrChBU4pGS12lU4KbcwoVQGf9mUUj5XQ16BgrQ96Fs2/KErgbZ24/2ZA7 GV84g65IiLiYiyI/u1d+sG9v3SHZseHeRsnL80hZv441oVjy7uh/842lkBk3Kcg41lMCqo 1maZS125V7rwh4xjCMxxB7hUKrXHQFF/hm2LqtEBfIvfbBT5tmqxnTjPxjpExL3fXmvnSF 3ZLYUPzSWOJyc/Fraeg4hEC2HDX8SDWST3Jy3axt3qaeXhQkDDtUwiPiK9s7hr0ErP6efy e0esL/fqeqyloKY0tpdeSb+LjjavmLYot0r0kyyuZgfE2gYbpVV2sPdOiN6L1A== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1633396638; a=rsa-sha256; cv=none; b=bR0UsqSkwiJ7JlOjwHa+TTv42pzAk2TwpH+T3/TJUFgrkEbe9KbC/W2ELsGFFCCQmg/bYP 8FUs7dJAnhKoSdBI1OXziPUZ0hXNVQ69vAYBrLrYqNAyEyAw1PqtseF+y45EkuX/fI1WE6 baNE0SmRhFJI3FAjdRVHv6i6kHe91f6R9tDoH4kh/OL8F6Df9X2bsXuTexX+JDJUCfnTpr MCVCveLq/pb5pwwaCwUzWcFhSDd8DfK5CHDYcTeUODYkq2CFXMecLoBZhFCmWJ+83GhbjC uxAVOu8QWk9LAuO7f582fvXKP8uWi2iRHuhjVuyjhRDqLE0o/2R9Ote4iE0V5w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=vicarious-living-com.20210112.gappssmtp.com header.s=20210112 header.b=I0uJBUif; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -1.41 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=vicarious-living-com.20210112.gappssmtp.com header.s=20210112 header.b=I0uJBUif; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: D954C144FE X-Spam-Score: -1.41 X-Migadu-Scanner: scn0.migadu.com X-TUID: vYn6sk6RWGpe --00000000000083835605cd90a1cf Content-Type: text/plain; charset="UTF-8" I've been working through a few different approaches. What's shaping up is something more general, having a special value for directory parameters (i.e. 'attach) and auto-detection of link paths that are in the attachment directory. The latest iterations don't move any files around, so can't actually enforce the output directory. That makes it safer overall as with my initial patch if you were to return a path to something you *didn't* want moved to your attachment directory you might get very surprising results. I'll post a new patch with a different approach in a little bit. On Mon, Oct 4, 2021 at 5:06 PM Christopher M. Miles wrote: > Ihor Radchenko writes: > > Greg Minshall writes: >> >> i can imagine wanting to have input files and output files in separate >>> directories. (for ease in "make clean", if for no other conceptual reason.) >>> (but, probably i don't understand.) >>> >> I agree with this thought. We should separate two directories. > > Makes sense. Currently, there is :dir header arg to set working directory >> (aka input files directory). Maybe we can introduce something like >> :results-dir header arg to set the output directory? It's value can be a >> directory path or symbol 'attach. >> >> `:results file :results-dir 'attach` will be equivalent of `:results file >> attach` in the patch proposed by Ryan Scott. >> >> WDYT? >> > I agree with this idea. Use :results-dir 'attach is better. > > Will the patch be updated? > > Best, Ihor >> > > <#secure method=pgpmime mode=sign> > -- > [ stardiviner ] > I try to make every word tell the meaning that I want to express. > > Blog: https://stardiviner.github.io/ > IRC(freenode): stardiviner, Matrix: stardiviner > GPG: F09F650D7D674819892591401B5DF1C95AE89AC3 > --00000000000083835605cd90a1cf Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I've been working through a few different approac= hes. What's shaping up is something more general, having a special valu= e for directory parameters (i.e. 'attach) and auto-detection of link pa= ths that are in the attachment directory.
The latest iterations d= on't move any files around, so can't actually enforce the output di= rectory. That makes it safer overall as with my initial patch if you were t= o return a path to something you didn't want moved to your attac= hment directory you might get very surprising results.

=
I'll post a new patch with a different approach in a little bit.

On Mon, Oct 4, 2021 at 5:06 PM Christopher M. Miles <numbchild@gmail.com> wrote:

Ihor Radchenko <= yantar92@gmail.com> writes:

Greg Minshall <minshall@umich.edu> writes:

i can imagine wanting to have input files and output files in separate directories. (for ease in "make clean",= if for no other conceptual reason.) (but, probably i don't understand.)

I agree with this thought. We should separate two directories.

Makes sense. Currently, there is :dir header arg to set working directory (aka input files directory). Maybe we can introduce something like :results-dir header arg to set the output directory? It's value ca= n be a directory path or symbol 'attach.

`:results file :results-dir 'attach` will be equivalent of `:results file attach` in the patch proposed by Ryan Scott.

WDYT?

I agree with this idea. Use :results-dir 'attach is better= .

Will the patch be updated?

Best, Ihor


<#secure method=3Dpgpmime mode=3Dsign>
--
[ stardiviner ]
=C2=A0 =C2=A0 =C2=A0 =C2=A0I try to make every word tell the meaning that I= want to express.

=C2=A0 =C2=A0 =C2=A0 =C2=A0Blog: https://stardiviner.github.io/ =C2=A0 =C2=A0 =C2=A0 =C2=A0IRC(freenode): stardiviner, Matrix: stardiviner<= br> =C2=A0 =C2=A0 =C2=A0 =C2=A0GPG: F09F650D7D674819892591401B5DF1C95AE89AC3
--00000000000083835605cd90a1cf--