From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 14206 invoked from network); 2 Feb 2021 19:17:02 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 2 Feb 2021 19:17:02 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1612293422; b=qKw4HaLY0ZrwXiUsReQZXUQehlGGvIBSvQU+EoA9RDXFxXq5/Zt1PdqQbRgQbSYRkAXnPQ9mZp l8+E/tnMbwPTCk/fFNRVBtPIBMLuDzXI4qu4ijTxb9hCBSHlhLCCR335qYEtPIVc/xlKUS3gtL Mdu4oTPhLnBhH5diwbdTx+/TAyigoL0ccGOGP9BXz6pByRpnNsn1lwP13+ffi+C42of9rsr46+ KHB2RukAeWvcLVHlzrzylvhbJ4f1hrBEWA5itvdTUwheEBDqwPeqOnRy9iN0NGvM/aj27SmW54 HGr8oyC9XzZtzUfo93Rza/5ZgSFrJa7/7brAkaNVDm2AGw==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mta02.eastlink.ca) smtp.remote-ip=24.224.136.13; dmarc=none header.from=eastlink.ca; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1612293422; bh=OqP0eWkdLVlJOo53xIxHlRe3oZazHDNKMqbXVPQ5NKw=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Transfer-Encoding:Content-Type:MIME-Version:Date: Message-ID:Subject:From:To:DKIM-Signature; b=DVHfaM0zRiebZdkLoTeVD4kUfXECsn8StneCBtaQ2t2B8+DQnULpnYsMkNaomhW92+CbeSZDii U7gTcYzxRsicS9sAB9Tk8Wn+WMUh6NVsVXGolvzIeRPLWwfegO7miQUK9sSo3715IxdZJNQvgY jIDFZuDWIYy5QkglhWEh87lUDRteZEBWJwI+ZsY0G3pqt3TnuEl2BViAK0wLjBP7x4lgsYBsai C3dfqh4OWk++ju9S+1rHs6b80VGDIn2cfUy7oDqaYl6gcua48jJiOs8ZSt2YD36uLmILj41Rkv g/GXzA9jDYuGHZDm2hTMP4Jczz1eGRF+xfWL51Qt+vMFQw==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-transfer-encoding: Content-type:MIME-version:Date:Message-id:Subject:From:To:Reply-To:Cc: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References; bh=jdD/+DEEefkyV5O3jaUxhrJfPE6KPt5e6YX7SwdD6pA=; b=cLkskp66UvHXSmqxm8NXmoaDu2 JkEYysejrvCt87PbMmdlxX3VqSjiKrlSeAoZoXUjdeadPK3HdeFvp81X1plQx2ev9qo8ydixM3q9t gaMOhxD9h6YKC8TIbBeduBkQ5VCW9YwHrdgC/6LOG/lw+B2ClpalRhRQgnhDTgQp/e6W52+Yicm1y pP4YeV23aiRyfnpoxaMI67lFByAKNwLpJ8isetncDoVC5k/rZW/ZIIX+B64DNC23OZTgkWdMsc8pR qAB/LJ1/dOyUa6tmPKXMzd9cpk+q1oaX4cqct9m9vbNbZPb8JEZjx7Lrz4qf4uyFV350KeB1d8meq 18T8sJew==; Received: from authenticated user by zero.zsh.org with local id 1l71Aa-000GmL-IN; Tue, 02 Feb 2021 19:17:00 +0000 Authentication-Results: zsh.org; iprev=pass (mta02.eastlink.ca) smtp.remote-ip=24.224.136.13; dmarc=none header.from=eastlink.ca; arc=none Received: from mta02.eastlink.ca ([24.224.136.13]:40207) by zero.zsh.org with esmtps (TLS1.2:ECDHE-RSA-AES128-GCM-SHA256:128) id 1l71A7-000GQV-7A; Tue, 02 Feb 2021 19:16:33 +0000 Received: from csp01.eastlink.ca ([71.7.199.166]) by mta02.eastlink.ca (Oracle Communications Messaging Server 8.0.2.2.20180531 64bit (built May 31 2018)) with ESMTPS id <0QNW001YMZQQ6LM0@mta02.eastlink.ca> for zsh-users@zsh.org; Tue, 02 Feb 2021 15:16:28 -0400 (AST) Received: from [192.168.0.3] ([24.207.90.194]) by Eastlink with ESMTP id 71A3lIUYwsAqK71A4lWr8j; Tue, 02 Feb 2021 15:16:28 -0400 X-Authority-Analysis: v=2.4 cv=W6f96Tak c=1 sm=1 tr=0 ts=6019a50c a=zv49KfEsxEDzuN5AGO7r0Q==:117 a=zv49KfEsxEDzuN5AGO7r0Q==:17 a=IkcTkHD0fZMA:10 a=tUvHm60NKSk6qWzaD7cA:9 a=QEXdDO2ut3YA:10 X-Vade-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrgedtgdduvdefucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecugfetuffvnffkpffmpdfqfgfvnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefvhffukffffgggtgfgsehtkeertddtfeejnecuhfhrohhmpeftrgihucetnhgurhgvfihsuceorhgrhigrnhgurhgvfihssegvrghsthhlihhnkhdrtggrqeenucggtffrrghtthgvrhhnpeetvefgtdfgueegveduhfelffegteegheeugfegveehkeeftdehjedugedutddtheenucfkphepvdegrddvtdejrdeltddrudelgeenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepihhnvghtpedvgedrvddtjedrledtrdduleegpdhhvghloheplgduledvrdduieekrddtrdefngdpmhgrihhlfhhrohhmpehrrgihrghnughrvgifshesvggrshhtlhhinhhkrdgtrgdprhgtphhtthhopeiishhhqdhushgvrhhsseiishhhrdhorhhgpdhgvghtqdgkihhprfgrshhsfigupehtrhhuvg X-Vade-Score: -100 X-Vade-State: 0 X-EL-IP-NOAUTH: 24.207.90.194 To: Zsh Users From: Ray Andrews Subject: array with newlines preserved as literal text Message-id: <52dba8e4-2538-7c96-ecd5-66e017ab2b8e@eastlink.ca> Date: Tue, 2 Feb 2021 11:16:27 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.6.0 MIME-version: 1.0 Content-type: text/plain; charset=utf-8; format=flowed Content-transfer-encoding: 8bit Content-language: en-US X-Seq: 26449 Archived-At: X-Loop: zsh-users@zsh.org Errors-To: zsh-users-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-users-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: Archived-At: I create some nasty output involving a grep search, save to to a variable, send it to a function which ends up calling 'eval' which receives the input and executes it like this:     @ eval "$@"     echo "\nYou (hard return)     will\\nregret'\x0a'\nthe day you '\n' were born." ... I can save the output to a file perfectly:     $ eval "$@" >! junk     $ cat junk     echo "\nYou (hard return)     will\\nregret'\x0a'\nthe day you '\n' were born."   # Perfectly identical. ... and I can recapture that text from the file to a variable like this:     $ typeset -a array1=( "${(q+)$(