From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id mC29DlRYbGcpPwEAe85BDQ:P1 (envelope-from ) for ; Wed, 25 Dec 2024 19:09:08 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e16b::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id mC29DlRYbGcpPwEAe85BDQ (envelope-from ) for ; Wed, 25 Dec 2024 20:09:08 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=outlook.com header.s=selector1 header.b=VTj0qghT; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=outlook.com; arc=pass ("microsoft.com:s=arcselector10001:i=1") ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1735153747; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=BqWmn8FnhBRAdKJ1atGEH61C6REpgmO3t7wPwIgOy/g=; b=rH+CUUX/zByz4iFLT8d6EzdQs4GqZxiiZ0rXKWday//wz3ZcYopLvQdt9ro9VRM7nHW7tx n71xla3KPzijH62vVfetKggDxD7+1q+l2St+sTbDlo863J8KdE+jG5m9pTqisDTeyr8i4R zPsTquRDeG9AjzgBr0AZL9oaxJHcveNQf+7Li9CZXehSSk62sQUyddU+yWf3H6TCpOjxP9 OHNPJnFh8xkjHQ5WsFrzdgfaXkDcNrQFDKWwqfIk2yXH4IFeQGY4qNlt9Y16t39ATKlDQQ R7Jy8eSPC+n2keBQ8pbndSlGwa4iNVf6t2lLdGkaDWABohaonPBtS1HPvpvTNQ== ARC-Authentication-Results: i=2; aspmx1.migadu.com; dkim=pass header.d=outlook.com header.s=selector1 header.b=VTj0qghT; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=outlook.com; arc=pass ("microsoft.com:s=arcselector10001:i=1") ARC-Seal: i=2; s=key1; d=yhetil.org; t=1735153747; a=rsa-sha256; cv=pass; b=h9nBNclTxGjIP3yPSU/A0ePJgPx50mvkQAOzRWdNZ2pN9mGZ5phMFC+dCXw3QgF29Zfgzi lnNEF7cZVxqaTMEQ7+9vYrSaHSaFEcVBdACaoxVeXKD64mIFFzqXARei+CXYdL+idVJtpM z9Tub9PrRbzglX6sIglibLF4sS1ekaUs6i3Xu8y0TRZuTUpZJEKz6IfGDrfa3MK9mZxvdY 3k9dhXgbCwUdf6yE5HwmG9GCCwqVbvEWuG+I7oPkTPjd+PSSS/aSzYv1n4PLnNHDdW+t6K hqq361BLK4VEXPeuWLKx+B8pBFpFLmQNdtNFHm14Ple8TBIpRGjbn1sIvBUIsg== 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 159C6828E7 for ; Wed, 25 Dec 2024 20:09:07 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tQWk6-0008G9-Nu; Wed, 25 Dec 2024 14:08:26 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tQWk3-0008EZ-5E for emacs-orgmode@gnu.org; Wed, 25 Dec 2024 14:08:23 -0500 Received: from mail-db8eur05olkn2020.outbound.protection.outlook.com ([40.92.89.20] helo=EUR05-DB8-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tQWk1-0005my-6H for emacs-orgmode@gnu.org; Wed, 25 Dec 2024 14:08:22 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=uSWyDWyAI9kkirir08wxJmXs5j/1QsJ39MjIhe/btckyVlu7Mh4adlaVlZc9QDQ+6IhSf3kNgjtXH9g+9bR5KXRChNVOQEhqRFlCTfv2FVjmnZNK2cTM6rChe3KX19FXYD4KshQQ7yNV4ayFidzRGDjpyaSh8x8dcOyf4qtFG/o8O9xhf4mm3uyTy644EL5yVsboFGRZ2nnp8JlEbB6LLfl5X9B4lw8xzDrbZXFHoJDTZ+0U+ZlB4i/mUIyWkal27ra2KGG3zbSveruQMaP/X+ZhdsVkQ/dXhqQQ1eYpRutW6pOz0/nt4zfVWn1W1fNxgw0uVUugcI5WT/viB3EeFw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=BqWmn8FnhBRAdKJ1atGEH61C6REpgmO3t7wPwIgOy/g=; b=AlmmqO7GiGzpTgLA9h0UmH3r+/S3EwCsnp/59sj8Aq365uY+1v1225XMsF9xposvNqckCktpWT7FIoA29wXz9Mt1HjSNxJ3eZ9hs/ShwEygTA/S7LnczKJYHxQm60c8GRlN8pdZT+BS5c0ovcp+c9FUN3LXis/YzppuQ8/vCFKmdGirZ4oXqrkJUlesIL3B6vWM43XJf2mE3U7BW39fDdGGViqJ6ZMWAnLcVrzA284dYc3l0BGd/UXf0E75wAanU9jGcjQ7yucmdfghHUurHAVju6gy+i5139BfQRZohYiOJUi5wJPYUh+8++2yBiKJz92Qjxh6FKbI9yzf3HBzmUQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=BqWmn8FnhBRAdKJ1atGEH61C6REpgmO3t7wPwIgOy/g=; b=VTj0qghTRV3v+ztqMp14ucH0g9NGCEV65gQJoWY1zP/wvaOYt+bfpAOPEt0H5NpKRFUx5q9UKrXZcUzKIyDWEfCvOs6VYKTifFu7q3Wgkgb9qbJ2qJqFMMBpYuVGX6uw7AlmP7GGe2eymmU2L2nYvjrfZtlXRkm9Y6s8nByB5Vdt+G/eJjs/DDsvc891TNc/VXdA3U9FklkK/yX44+MGuiDxPDrUOob0QpS+TSJTkX1Job/Y1BXX4CqpAL6H3piMDBx1CIWP/cljipvLw7YGVe4J+Y4E0ciW6wzbd89nqQ3JG9zwl497CnWz4o9yY+azYPadykHna6PaRtDOYP6pSQ== Received: from DU2P250MB0206.EURP250.PROD.OUTLOOK.COM (2603:10a6:10:277::8) by AS4P250MB0683.EURP250.PROD.OUTLOOK.COM (2603:10a6:20b:4be::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8272.20; Wed, 25 Dec 2024 19:03:15 +0000 Received: from DU2P250MB0206.EURP250.PROD.OUTLOOK.COM ([fe80::f83a:2dd9:d1ec:81c1]) by DU2P250MB0206.EURP250.PROD.OUTLOOK.COM ([fe80::f83a:2dd9:d1ec:81c1%3]) with mapi id 15.20.8272.013; Wed, 25 Dec 2024 19:03:15 +0000 Message-ID: Date: Wed, 25 Dec 2024 19:03:14 +0000 User-Agent: Mozilla Thunderbird Subject: Re: Generating the filename from name and file-ext for blocks with side-effects To: Ihor Radchenko Cc: emacs-orgmode@gnu.org References: <874j2rzso6.fsf@localhost> Content-Language: en-GB From: Aitenate In-Reply-To: <874j2rzso6.fsf@localhost> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: CWLP265CA0286.GBRP265.PROD.OUTLOOK.COM (2603:10a6:401:5c::34) To DU2P250MB0206.EURP250.PROD.OUTLOOK.COM (2603:10a6:10:277::8) X-Microsoft-Original-Message-ID: MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DU2P250MB0206:EE_|AS4P250MB0683:EE_ X-MS-Office365-Filtering-Correlation-Id: f07ec89d-6b8c-4727-bfbf-08dd2516c976 X-Microsoft-Antispam: BCL:0; ARA:14566002|7092599003|6090799003|5072599009|19110799003|461199028|15080799006|8060799006|440099028|3412199025|3430499032; X-Microsoft-Antispam-Message-Info: =?utf-8?B?elRwTFFkL2lwdXFtN1JOWW91dTljVXhXSUpmRFRKd2xoVEhPUnZ1cmd3amtk?= =?utf-8?B?NzRROGMzbWdhQzZEOEg5bEtuS3FEMEg4anduVmxpS3c4MEVyYnhybjhPUUZ1?= =?utf-8?B?dmc1THBidnBpV2JtZ3BRSjl2MEZxenpYMGFGMkdlSmdTZk1EMFNmVFdHaDla?= =?utf-8?B?dGZmcmNzUWFOZlFlUlZ1OXFHUjF3RUpUSU5RUnRHM3VoZDBlS2pmNng1eW50?= =?utf-8?B?Mk9iZ0xVK1JaeTZjRjRvNmF0NjFvQVN5cjFTRWROTmtjU2Q1d3dscXlHdkcx?= =?utf-8?B?Y1RNdGpYMU9qRDFSVG82WUlKQVNBNlcrTktYKzRNYW5iZ1BEd2lpM3BVMGFW?= =?utf-8?B?cGZoZk02V2loY3JDWlFCb1Jr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KWTI4UFlFUWhGczJqdTVP?= =?utf-8?B?VG1hS0JuL2tndVNpcDdTTmVrQ2VtaUNGVGtXdjlBMTMxdjRLejZ5eFRYZVVH?= =?utf-8?B?ZjQ5cmlyRC8waXVjUW92ZTF6RlRLU2RVc1ZVZiswWUlYNGp3Y2ZtbExvblNR?= =?utf-8?Q?Z/wm7SPIDi//CZC9HbNbUxJSB2olO6+u4iEN9U6TVj60=3D?= X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: f07ec89d-6b8c-4727-bfbf-08dd2516c976 X-MS-Exchange-CrossTenant-AuthSource: DU2P250MB0206.EURP250.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Dec 2024 19:03:15.7873 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS4P250MB0683 Received-SPF: pass client-ip=40.92.89.20; envelope-from=aitenate@outlook.com; helo=EUR05-DB8-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Queue-Id: 159C6828E7 X-Migadu-Scanner: mx13.migadu.com X-Migadu-Spam-Score: -5.20 X-Spam-Score: -5.20 X-TUID: R+kSqghf/faU On 25/12/2024 15:30, Ihor Radchenko wrote: > Aitenate writes: > >> With ~:results file~, the absence of ~:file~ will cause the filename to >> be constructed from the block name and ~:file-ext~, if they are both >> present. To achieve that with ~:results file link~, I could only come up >> with >> >> ~:var outFile=(alist-get :file (nth 2 (org-babel-get-src-block-info >> 't)))~ > > Seems right, but I do not understand why you would need such thing. > The aim is to not need to define a filename for each image, to minimise the boilerplate. Org has a mechanism for this, but it only works when Org creates the file. Using a combination of noweb and file header arguments, with a property drawer, I was able to have each code block only require a unique name and the image code. That is except, because the image library creates the file, I need to specify a var to give a filename. Hence, I poked around until I found a way to use the computed filename. While I'm happy with the solution I found, as a novice Org user, it seemed like I needed to reach into undocumented internals to do this. So I queried this, partly to understand if there was a better way, and partly to see if it was worth providing a better way or at least documenting a method. Based on your response, maybe I'm doing something unusual. In which case, it's not surprising I couldn't find a more obvious way.