From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id aOZxNbdWcWN0MwAAbAwnHQ (envelope-from ) for ; Sun, 13 Nov 2022 21:42:31 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id QM9vNbdWcWMhXAEA9RJhRA (envelope-from ) for ; Sun, 13 Nov 2022 21:42:31 +0100 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 578ABCB69 for ; Sun, 13 Nov 2022 21:42:31 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ouJnF-00020L-2d; Sun, 13 Nov 2022 15:41:29 -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 1ouJnD-0001zZ-EL for emacs-orgmode@gnu.org; Sun, 13 Nov 2022 15:41:27 -0500 Received: from smtpout02-ext4.partage.renater.fr ([194.254.241.31]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ouJnA-000249-Gd for emacs-orgmode@gnu.org; Sun, 13 Nov 2022 15:41:27 -0500 Received: from zmtaauth04.partage.renater.fr (zmtaauth04.partage.renater.fr [194.254.241.26]) by smtpout20.partage.renater.fr (Postfix) with ESMTP id 77098BFD09; Sun, 13 Nov 2022 21:41:17 +0100 (CET) Received: from zmtaauth04.partage.renater.fr (localhost [127.0.0.1]) by zmtaauth04.partage.renater.fr (Postfix) with ESMTPS id 6E9D71C0052; Sun, 13 Nov 2022 21:41:17 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by zmtaauth04.partage.renater.fr (Postfix) with ESMTP id 5E7EC1C007C; Sun, 13 Nov 2022 21:41:17 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.10.3 zmtaauth04.partage.renater.fr 5E7EC1C007C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=unistra.fr; s=CF279DD4-6F58-4C59-BB33-73FDC6DFC1E3; t=1668372077; bh=ahGHH+1kE4rAh1JNmExMsn0e6gEeAmlB0EL3QiV2PpI=; h=MIME-Version:Message-ID:Date:From:To; b=dQhokY/IgXY7XH5LSBGP8EKaS00Rr2SM4R5ibbMi0yP2oF1e++8EzrF/ahBHCttaf q8cML3iQZ7mnPoBIYgzmAr9yrci5KPknxijYYoPYrrVw6I/y5BPxLbqRCbLgavd3VY s0MzxKFE59wEbrtyEZe0wJTY9wW++GTYvTx3NfbRh52WajLQb88/rHEACZcji28MHr LHQEEypm7nh707Zcf58LfnA8aaRFibglHbK8wqQmRSnUEI55HxV71lm0ZfrvV6SSGj qRYcmYi2EtngJkpMfCSfRkQFFtxuQYr5e4O6ntk149SapMGMwkizJ6BqVz/mjV4LRd ZWBe/efebPlqw== Received: from zmtaauth04.partage.renater.fr ([127.0.0.1]) by localhost (zmtaauth04.partage.renater.fr [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id KV1oz0WrCYIO; Sun, 13 Nov 2022 21:41:17 +0100 (CET) Received: from 90.33.144.90 (unknown [194.254.241.251]) by zmtaauth04.partage.renater.fr (Postfix) with ESMTPA id BB0151C0052; Sun, 13 Nov 2022 21:41:16 +0100 (CET) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Message-ID: <25457.22124.839301.412560@gargle.gargle.HOWL> Date: Sun, 13 Nov 2022 21:41:16 +0100 From: Alain.Cochard@unistra.fr To: Ihor Radchenko Cc: alain.cochard@unistra.fr, Org Mode List Subject: Re: 2 'echo' bash instructions produce a table In-Reply-To: <87tu3ba40w.fsf@localhost> References: <25447.23346.575598.420558@gargle.gargle.HOWL> <87tu3ba40w.fsf@localhost> X-Mailer: VM 8.2.0b under 27.2 (x86_64-redhat-linux-gnu) X-Virus-Scanned: clamav-milter 0.103.6 at clamav02 X-Virus-Status: Clean X-Renater-Ptge-SpamState: clean X-Renater-Ptge-SpamScore: -100 X-Renater-Ptge-SpamCause: gggruggvucftvghtrhhoucdtuddrgedvgedrgedtgddugeduucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecutffgpfetvffgtfenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhepgggtgffkfffhvfevufgjfhforhesthhqredtredtjeenucfhrhhomheptehlrghinhdrvehotghhrghrugesuhhnihhsthhrrgdrfhhrnecuggftrfgrthhtvghrnhepgeehueekveejvefhtdekvedugeeugfekfefhjeejfeevtdfhudffiefgieeihfdtnecukfhppeduleegrddvheegrddvgedurddvhedunecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehinhgvthepudelgedrvdehgedrvdeguddrvdehuddphhgvlhhopeeltddrfeefrddugeegrdeltddpmhgrihhlfhhrohhmpeetlhgrihhnrdevohgthhgrrhgusehunhhishhtrhgrrdhfrhdpnhgspghrtghpthhtohepfedprhgtphhtthhopegvmhgrtghsqdhorhhgmhhouggvsehgnhhurdhorhhgpdhrtghpthhtoheprghlrghinhdrtghotghhrghrugesuhhnihhsthhrrgdrfhhrpdhrtghpthhtohephigrnhhtrghrledvsehpohhsthgvohdrnhgvth Received-SPF: pass client-ip=194.254.241.31; envelope-from=Alain.Cochard@unistra.fr; helo=smtpout02-ext4.partage.renater.fr X-Spam_score_int: -3 X-Spam_score: -0.4 X-Spam_bar: / X-Spam_report: (-0.4 / 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, NICE_REPLY_A=-0.001, RCVD_HELO_IP_MISMATCH=2.368, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no 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: , Reply-To: alain.cochard@unistra.fr Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1668372151; h=from:from:sender:sender:reply-to: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=ahGHH+1kE4rAh1JNmExMsn0e6gEeAmlB0EL3QiV2PpI=; b=Tf+bpEAhyseQGwSNZho0hRHFAWkpUj8zcSUJJXQ6pbT539l18CMz/fqfZCQb53J9YmRYP1 sJ9xPSmVRAXL8iDqfFDZKGzn5tF/INpSWrluZJtQA5J3RFdW/JZYr058rkI3kP6qi4QDYv lKZNA0iWoOKYuFSckJOit+yQQ3aOHG7GSX6Y6MGHNlCMM1rOfMmFuKHDCDJrMlcBNdQmCZ vtT8cq+9Cr6JfZbmKhwafwPE5BU6huXMYE7oRrrb0dMVzQwnJPlo7qq0gjnr3wv3Zu7tAN ezDHtPkH+yUV5AdptNLPAItjUyNZg6i89VvlIlrjDUFG3yj12nIybmSr0kBOlQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1668372151; a=rsa-sha256; cv=none; b=MGxvnXXfwait/Vs5Cn8gdojYWkmlGO5eB5MAL0XlQWWghmdAFhu3FA7GVs+3jP+sL04sAu W0rFLw2w8R/IXozX3RN/3hpgMeFPM+jczWMa5erDxjgXYel0ums/F5VqY/S9DVo2vQziTn 5G9OJ6cYgaGI2laOKphQws3zRQQjzJpn9jrf+DiP6Qrbdxc9E9sMiRwEGH64TZphHlW3IH dMbvqvqOp7en7j6U8WpJ1LrBunEC8IkUdR/t2TLqDzjpe+TGcFLG2BkcXloCO5O4A8yYll I+XV+yF6VG/cNK/uCRgCOxUaKhOnsElu999vhZ0h3WbCcKWYZN+d0L/hn3Dzhg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=unistra.fr header.s=CF279DD4-6F58-4C59-BB33-73FDC6DFC1E3 header.b="dQhokY/I"; dmarc=none; 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" X-Migadu-Spam-Score: -6.85 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=unistra.fr header.s=CF279DD4-6F58-4C59-BB33-73FDC6DFC1E3 header.b="dQhokY/I"; dmarc=none; 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" X-Migadu-Queue-Id: 578ABCB69 X-Spam-Score: -6.85 X-Migadu-Scanner: scn0.migadu.com X-TUID: euS4ngq42O4R Ihor Radchenko writes on Mon 7 Nov 2022 02:31: > If you want to force string output, use :results output. >=20 > By default, ob-shell tries to guess the output type. In the case > of two commands returning output, the guess is yielding the > table. In the case of a single command, the guess is yielding a > single string output. Thanks a lot. I find it strange, though, that the default is not as what one gets from running the code from a terminal. I imagine there are good reasons for that, but I think this should be made clear (or at least clearer) in the manual. I browsed through section 16 of the manual, with particular attention to 16.5 (Evaluating Code Blocks) and 16.6 (Results of Evaluation), but still cannot see where this is said or hinted; if it is there, I missed it or do not know enough to understand it. For the sake of newcomers, it seems to me that something along the line of what you write above would fit somewhere in 16.6, with a first short mention/warning (and reference to it) next to that excerpt in 16.5: Org captures the results of the code block evaluation and inserts them in the Org file, right after the code block. Regards. PS1 In section 16.3 of the manual (Using Header Arguments): System-wide values of header arguments can be specified by customizing the =E2=80=98org-babel-default-header-args=E2=80=99 vari= able, which defaults to the following values: =09:session =3D> "none" =09:results =3D> "replace" =09:exports =3D> "code" =09:cache =3D> "no" =09:noweb =3D> "no" but the docstring of 'org-babel-default-header-args' says: org-babel-default-header-args is a variable defined in =E2=80=98ob-c= ore.el=E2=80=99. Its value is ((:session . "none") (:results . "replace") (:exports . "code") (:cache . "no") (:noweb . "no") (:hlines . "no") (:tangle . "no")) so I was wondering if there should be :hlines =3D> "no" :tangle =3D> "no" added above. PS2 In section 16.6 (Results of Evaluation) =20 [The =E2=80=98results=E2=80=99 header argument] accepts four classes= of options [Collection, Type, Format, Handling] Each code block can take only one option per class: Now, the paragraphs related to Collection, Type, & Format all contain the statement "Choose one of the options; they are mutually exclusive". I thought this statement was saying the same thing as the "only one option per class" above, but then why not also repeat the statement in the Handling paragraph=3F PS3 In section 16.4 (Environment of a Code Block) A simple named list. =09 #+NAME: example-list =09 - simple =09 - not =09 - nested =09 - list =09 #+BEGIN=5FSRC emacs-lisp :var x=3Dexample-list =09 (print x) =09 #+END=5FSRC =09 #+RESULTS: =09 | simple | list | But if I evaluate the code, I get =09 #+RESULTS: =09 | simple | (unordered (not) (nested)) | =09 | list | | PS4 In 16.5 (Evaluating Code Blocks), in this code #+NAME: random #+BEGIN=5FSRC R :cache yes runif(1) #+END=5FSRC the (1) seems to be understood as a footnote in Info, at least for me. E.g., on it goes to the footnote (1) The option =E2=80=98org-babel-no-eval-on-ctrl-c-ctrl-c=E2=80=99 = [...] and on this (1) goes back to the above code instead of to the actual call "Org provides many ways to execute code blocks. =E2=80=98C-c C-c=E2= =80=99 or =E2=80=98C-c C-v e=E2=80=99 with the point on a code block(1)" =20 --=20 EOST (=C3=89cole et Observatoire des Sciences de la Terre)=20 ITE (Institut Terre & Environnement) | alain.cochard@unistra.fr 5 rue Ren=C3=A9 Descartes [bureau 110] | Phone: +33 (0)3 68 85 50 44= =20 F-67084 Strasbourg Cedex, France | [ slot available for rent ]