From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id mHQAL0NUU2CUJQAA0tVLHw (envelope-from ) for ; Thu, 18 Mar 2021 13:23:15 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id mF/dKkNUU2C5AQAAbx9fmQ (envelope-from ) for ; Thu, 18 Mar 2021 13:23:15 +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 2F5F927BF3 for ; Thu, 18 Mar 2021 14:23:15 +0100 (CET) Received: from localhost ([::1]:52112 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lMscL-00054U-Fj for larch@yhetil.org; Thu, 18 Mar 2021 09:23:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41238) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lMsbU-00054M-L2 for emacs-orgmode@gnu.org; Thu, 18 Mar 2021 09:22:20 -0400 Received: from outpost1.zedat.fu-berlin.de ([130.133.4.66]:39701) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lMsbS-0006qc-K3 for emacs-orgmode@gnu.org; Thu, 18 Mar 2021 09:22:20 -0400 Received: from inpost2.zedat.fu-berlin.de ([130.133.4.69]) by outpost.zedat.fu-berlin.de (Exim 4.94) for emacs-orgmode@gnu.org with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (envelope-from ) id 1lMsb6-000Tr8-Vh; Thu, 18 Mar 2021 14:21:57 +0100 Received: from 130-133-144-203.mna.fu-berlin.de ([130.133.144.203] helo=hornfels) by inpost2.zedat.fu-berlin.de (Exim 4.94) for emacs-orgmode@gnu.org with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (envelope-from ) id 1lMsb6-002FyU-Nl; Thu, 18 Mar 2021 14:21:56 +0100 From: "Loris Bennett" To: Org Mode Mailing List Subject: Re: Sharing variables between source blocks without session References: <87o8fjscia.fsf@hornfels.zedat.fu-berlin.de> <87r1kf6xdq.fsf@ucl.ac.uk> Date: Thu, 18 Mar 2021 14:21:56 +0100 In-Reply-To: <87r1kf6xdq.fsf@ucl.ac.uk> (Eric S. Fraga's message of "Tue, 16 Mar 2021 13:28:33 +0000") Message-ID: <87im5owqa3.fsf@hornfels.zedat.fu-berlin.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Original-Sender: loris.bennett@fu-berlin.de X-Originating-IP: 130.133.144.203 Received-SPF: pass client-ip=130.133.4.66; envelope-from=loris@zedat.fu-berlin.de; helo=outpost1.zedat.fu-berlin.de X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=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.23 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" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1616073795; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to: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; bh=8teyqwXrE7RW3bP9Ft97YXPrkDw7SXdmcP8ik3zdx7U=; b=ArWUDm5wCYAqQA+0QmYQlAMjJKrvZSlkYp0GfyRc6r12vWY82J6zolJqQiuXOU6fy8pboa eFFjhhfM9yCR6ivG36vLB/lyZkDEfqpi+TL+IZkBdLY7Ug/lSPCp/OKvoB5u1Xnor4Cf+7 jOz7onNAORn/ibxSN2KBMFLXwlszOcmdPVpllGmvsc+igyv0lc56TutuarI2E3aHSLxVMu S/hrt3BenMI1sFXnmGoaiug7UA1wxm17vysVBLKPTyUIYKx6vvM+h1wTBWkUWfbshA7oVC 60wDYAc5L+Vte0353K7oRLcbVyiu2YcZYAQU2ZuZDX4FmseZwCOR22Kg79Ld1g== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1616073795; a=rsa-sha256; cv=none; b=owdzh5FVC6ZfXu9mwv9nX4botaN+junL44XMrCDdib8cQERGcpwzA5sYNqTlSvET/OCV3p oFynAv1742+FHDAYekWVPswII0IGlx/WuxmZjpLQ5Wx0ijkZSbYs9svCaxpJ6RS+RU1Hmw QF7G+vaxYiof/9FSd6HcNVIU+urxnd+Dl0r5iMXfMpFehXXIuw5O14E9IQY05q06VzgOZV p/ycmvnZ5w64yavEbfyLOM62fRXN20qJMje/YSRLzFuwYY4A+h4mPaxRoseONw743fk6fd LCUlLy3a5tNfSyEvzd2pfQqGm+F2B5x+9M3AfctGHv/TPH2BWDAv7m1juarzkw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=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: -2.41 Authentication-Results: aspmx1.migadu.com; dkim=none; 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: 2F5F927BF3 X-Spam-Score: -2.41 X-Migadu-Scanner: scn0.migadu.com X-TUID: Qr5R0b+93f+s Eric S Fraga writes: > On Tuesday, 16 Mar 2021 at 09:56, Loris Bennett wrote: >> How can I avoid having to declare the variable 'user' for both blocks? > > I imagine you could use a property, as in > > #+property: header-args :var user=loris > > or even make it specific for the particular language. > > (untested) Thanks for point out using 'header-args;' as property. However, if I do the following, the variable is unset in the shell script: #+properties: header-args :var user=loris #+begin_src sh echo user: ${user} #+end_src #+RESULTS: : user: Is that supposed to work, or am I doing something wrong? Cheers, Loris -- This signature is currently under construction.