From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <emacs-orgmode-bounces+larch=yhetil.org@gnu.org> Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id KGcADIEw819lKQAA0tVLHw (envelope-from <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>) for <larch@yhetil.org>; Mon, 04 Jan 2021 15:13:05 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id eA70B4Ew8198FQAAbx9fmQ (envelope-from <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>) for <larch@yhetil.org>; Mon, 04 Jan 2021 15:13:05 +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 6DD019402D4 for <larch@yhetil.org>; Mon, 4 Jan 2021 15:13:04 +0000 (UTC) Received: from localhost ([::1]:34674 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <emacs-orgmode-bounces+larch=yhetil.org@gnu.org>) id 1kwRXY-00048G-V4 for larch@yhetil.org; Mon, 04 Jan 2021 10:13:02 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:53736) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <diego@zzamboni.org>) id 1kwRVn-0002ka-E1 for emacs-orgmode@gnu.org; Mon, 04 Jan 2021 10:11:11 -0500 Received: from mail-ej1-x632.google.com ([2a00:1450:4864:20::632]:42362) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <diego@zzamboni.org>) id 1kwRVk-0005Sx-6U for emacs-orgmode@gnu.org; Mon, 04 Jan 2021 10:11:11 -0500 Received: by mail-ej1-x632.google.com with SMTP id d17so37145833ejy.9 for <emacs-orgmode@gnu.org>; Mon, 04 Jan 2021 07:11:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zzamboni-org.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=O5cVeFVmdj1d0LZa4F4RMqavX17NVPjje7D/gseTKuw=; b=ZInHTfX8BRd257pLo8mwoxHwHdVVRqsj1iBIjItaedvXLC5qVOPeRIRPwcg5lQV8i0 UByD3dth1Akx4lPjDo1jW4NfKdpmDv6PzQENNk9fmTBmBDI3VotRr8jrYqQh1ZVoN+IZ 7I5vbQA8zP/et8vpsFwgPxxdXyd37KG2RE7wCST5EY/qdXPGL/BHGwCzS75kpclBXIYS vDrL0zEh7JL01izcK98L81endW0pBpPQY9OeoL+jDoRjp7RoIVSkz8ZYt4SeNvqunX9l pwYXng7DO5sV1H01MRAJXttfWUN2uu0kfjxA6vXHMQ5mOfuiA0l4RN0YRBsCQ2Yrw5fb aqSA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=O5cVeFVmdj1d0LZa4F4RMqavX17NVPjje7D/gseTKuw=; b=MucyzWiFtETmp7oI+wiaJ3LPwpm6tjB7BsivvlW82qphe5AkbqWCfLs+MBysxfbhkm MF2J87RCbzko3GIj6vlQXVTQxQs1CvjsomQ7lHAKjigDF9r09eokTJFRp1TLb15vrijM ZSJwqxVx/YXsIHPYVkmY2ODlad0HXe0iAI+BQs2NSEtkQ2pM3WPT6oR2ZKWd8gh5vFg4 ttKHqGXrtvo7euAhX4uknvFvhwDn3Qc/WO+ou3MmVz8HUlJMRhEq5ma19TT/Yp5XkAKs V4IXkOFvYkquYvdnLF/yg3E8ZVw9ihucwcZG1ctcgzbTMlcj1qFfH06Ed3V4r8W4g8Qq PY1g== X-Gm-Message-State: AOAM531kGXJxf+UefvPMqA1avw/KUePzraOXLsVrYQW9eejLvUYWxav3 w5sbbfv6/HWwdI/DhCrEvf0KhttCpERS77XnfH2NbQ== X-Google-Smtp-Source: ABdhPJxZwjL+cdJ+dwKi2/1ni12OqPmNG9HlfQ9g2+xBaEdBHTqbJsj4tmrNMBDg1kpo2Nr4am+rh0+l+vEVNAwjB3I= X-Received: by 2002:a17:907:28d4:: with SMTP id en20mr67977956ejc.196.1609773066723; Mon, 04 Jan 2021 07:11:06 -0800 (PST) MIME-Version: 1.0 References: <CA+pajWK-SE6iqLo7wgn2YPKJPP4JvsxgyhzUMKQNX+S6E_pSZg@mail.gmail.com> <CAM1nAcyA3zfoKjBapJhx4f5VaS9RUnY67ZiVk50XWMqrBfo5jg@mail.gmail.com> <CAGY83Ednxzmw7EvZNCTfLEhGf1DXg_9RhCOxva91uWgO49ZubA@mail.gmail.com> <CAM1nAcyUPB0GAWiCs4J6qxYzYsfbfGqNevO5C=m2ighKKYiaMQ@mail.gmail.com> In-Reply-To: <CAM1nAcyUPB0GAWiCs4J6qxYzYsfbfGqNevO5C=m2ighKKYiaMQ@mail.gmail.com> From: Diego Zamboni <diego@zzamboni.org> Date: Mon, 4 Jan 2021 16:10:55 +0100 Message-ID: <CAGY83EcjGPJnSkdJ=m47Yv7Z4Phg+sby_8bm8itiLwBoQN2sTg@mail.gmail.com> Subject: Re: ist here a :post header arg for tangling? To: Immanuel Litzroth <immanuel.litzroth@gmail.com> Content-Type: multipart/alternative; boundary="000000000000cfbc9805b8147fce" Received-SPF: none client-ip=2a00:1450:4864:20::632; envelope-from=diego@zzamboni.org; helo=mail-ej1-x632.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." <emacs-orgmode.gnu.org> List-Unsubscribe: <https://lists.gnu.org/mailman/options/emacs-orgmode>, <mailto:emacs-orgmode-request@gnu.org?subject=unsubscribe> List-Archive: <https://lists.gnu.org/archive/html/emacs-orgmode> List-Post: <mailto:emacs-orgmode@gnu.org> List-Help: <mailto:emacs-orgmode-request@gnu.org?subject=help> List-Subscribe: <https://lists.gnu.org/mailman/listinfo/emacs-orgmode>, <mailto:emacs-orgmode-request@gnu.org?subject=subscribe> Cc: gmauer@gmail.com, emacs-orgmode <emacs-orgmode@gnu.org> Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" <emacs-orgmode-bounces+larch=yhetil.org@gnu.org> X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -1.53 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=zzamboni-org.20150623.gappssmtp.com header.s=20150623 header.b=ZInHTfX8; 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: 6DD019402D4 X-Spam-Score: -1.53 X-Migadu-Scanner: scn1.migadu.com X-TUID: 54G4ykLBYWEa --000000000000cfbc9805b8147fce Content-Type: text/plain; charset="UTF-8" Agree. It should be possible to make the hook file-local, but still it's not trivial to have good control over where and how the changes are made. --Diego On Mon, Jan 4, 2021 at 3:51 PM Immanuel Litzroth < immanuel.litzroth@gmail.com> wrote: > There's that, but you're not gonna do much with that since it is > global to emacs. If you're brimming > with vigour you might achieve what you want by rebinding that each > time you tangle to do the correct > thing. Not much information is available in that hook, you get dropped > into a temp buffer containing the > result of tangling. > Immanuel > > On Mon, Jan 4, 2021 at 3:07 PM Diego Zamboni <diego@zzamboni.org> wrote: > > > > There's =org-babel-post-tangle-hook=, which AFAICT specifies hooks that > will be run with the tangled code in a temporary buffer. I couldn't find > much documentation nor examples, but it is mentioned at > https://orgmode.org/manual/Extracting-Source-Code.html#Hooks-3 > > > > --Diego > > > > > > > > > > > > On Fri, Jan 1, 2021 at 1:31 PM Immanuel Litzroth < > immanuel.litzroth@gmail.com> wrote: > >> > >> I don't think there is an arg for that. I have written a tangler that > >> reuses a lot > >> of the org-babel machinery and has a more flexible mechanism to decide > what > >> to do with the tangled code -- I use it for example to not write a > >> tangled file if it > >> hasn't changed, meaning that it will not trigger recompile. > >> The project is private now but if you're interested I can give you > access to it. > >> What exactly are you trying to do? > >> Immanuel > >> > >> On Fri, Jan 1, 2021 at 2:09 AM George Mauer <gmauer@gmail.com> wrote: > >> > > >> > I'd like to run some code to post-process files after they are > tangled. Is there a header-arg for that? > >> > >> > >> > >> -- > >> -- Researching the dual problem of finding the function that has a > >> given point as fixpoint. > >> > > > -- > -- Researching the dual problem of finding the function that has a > given point as fixpoint. > --000000000000cfbc9805b8147fce Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div dir=3D"ltr">Agree. It should be possible to make the = hook file-local, but still it's not trivial to have good control over w= here and how the changes are made.</div><div dir=3D"ltr"><br></div><div>--D= iego</div><div><br></div><br><div class=3D"gmail_quote"><div dir=3D"ltr" cl= ass=3D"gmail_attr">On Mon, Jan 4, 2021 at 3:51 PM Immanuel Litzroth <<a = href=3D"mailto:immanuel.litzroth@gmail.com">immanuel.litzroth@gmail.com</a>= > wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:0px = 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Ther= e's that, but you're not gonna do much with that since it is<br> global to emacs. If you're brimming<br> with vigour you might achieve what you want by rebinding that each<br> time you tangle to do the correct<br> thing. Not much information is available in that hook, you get dropped<br> into a temp buffer containing the<br> result of tangling.<br> Immanuel<br> <br> On Mon, Jan 4, 2021 at 3:07 PM Diego Zamboni <<a href=3D"mailto:diego@zz= amboni.org" target=3D"_blank">diego@zzamboni.org</a>> wrote:<br> ><br> > There's =3Dorg-babel-post-tangle-hook=3D, which AFAICT specifies h= ooks that will be run with the tangled code in a temporary buffer. I couldn= 't find much documentation nor examples, but it is mentioned at <a href= =3D"https://orgmode.org/manual/Extracting-Source-Code.html#Hooks-3" rel=3D"= noreferrer" target=3D"_blank">https://orgmode.org/manual/Extracting-Source-= Code.html#Hooks-3</a><br> ><br> > --Diego<br> ><br> ><br> ><br> ><br> ><br> > On Fri, Jan 1, 2021 at 1:31 PM Immanuel Litzroth <<a href=3D"mailto= :immanuel.litzroth@gmail.com" target=3D"_blank">immanuel.litzroth@gmail.com= </a>> wrote:<br> >><br> >> I don't think there is an arg for that. I have written a tangl= er that<br> >> reuses a lot<br> >> of the org-babel machinery and has a more flexible mechanism to de= cide what<br> >> to do with the tangled code -- I use it for example to not write a= <br> >> tangled file if it<br> >> hasn't changed, meaning that it will not trigger recompile.<br= > >> The project is private now but if you're interested I can give= you access to it.<br> >> What exactly are you trying to do?<br> >> Immanuel<br> >><br> >> On Fri, Jan 1, 2021 at 2:09 AM George Mauer <<a href=3D"mailto:= gmauer@gmail.com" target=3D"_blank">gmauer@gmail.com</a>> wrote:<br> >> ><br> >> > I'd like to run some code to post-process files after the= y are tangled. Is there a header-arg for that?<br> >><br> >><br> >><br> >> --<br> >> -- Researching the dual problem of finding the function that has a= <br> >> given point as fixpoint.<br> >><br> <br> <br> -- <br> -- Researching the dual problem of finding the function that has a<br> given point as fixpoint.<br> </blockquote></div></div> --000000000000cfbc9805b8147fce--