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 19827 invoked from network); 5 Feb 2021 03:23:24 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 5 Feb 2021 03:23:24 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1612495404; b=Gf/+09izNNRNh+MpnGiYpvvDYFbMuDOIbYCv+DW6H6ulK3jgcjynUp7+UsMHhphuwlnubJ1EYC p/grJ33XxVCAHTTTXsFnAeYC7a3Hpj3VZK0I4aS8oZzr+tJa+FkAXXVLk5UK5hpkjaCDqlp7/n kfymheubfPlU0fIDKee4twXMMUFCEtOdqJ+Rgn9QoLUbMtT6ZO+nY2vKJGHI83y6gkacxcGPZY fVNYnUnjy50rXWKE3yZcmj4dsKjc+UVRM1MRrn1Di2AXDP0642JJyex8dETnG8q8JGX2+FmASU /ijQCVXXJeSR+HNWjSoMBfwONwgK7z1oajskM040bOWjMg==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-oi1-f171.google.com) smtp.remote-ip=209.85.167.171; dkim=pass header.d=brasslantern-com.20150623.gappssmtp.com header.s=20150623 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20200801; t=1612495404; bh=NBfg0P4n5eUFC2Y/FN8kcNl2IuGV41dAOcc+8hpItlQ=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:DKIM-Signature:DKIM-Signature; b=WCxge45zIdDdgMGKgTSFCjbOkD61arHmzxMFbne5d+cC/DV1ZleEJVq2CpMcjEsDJxhBkuTxOl 7NTT1ja1ePEdLoN164zRahjpSjhHshBDB91oINzcUpU4+QBODzbly9+eaq6b611DVlm/P+lWrR LYuWkm4Qzqdc/2r0KnMNr8MzgfaEd3hbSbIfRDoJBe72ekeANorWmzPj/bkMnDelaVDcJBiXCK 0rxcQaXTR0xaA+TLA+W6kItkNpai/Oq/KOWwIPtsSLqM+wpYlV6MVFFGmZLGr1wFujaA+3Zx43 AZZoYq2bdPerl+zW3Weq4IKBbf0N5hN/iZh3PFRUQb6Ptg==; 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-Type:Cc:To:Subject:Message-ID :Date:From:In-Reply-To:References:MIME-Version:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=E6VmHipJztLQOR81MVegn6U52OfrYeCgJPvHUazVsh4=; b=MIonu0z7aEtNGBO9WO7SC42SXT pZQ3U5rjUZR7wvd5SIHVe3Sp/DY2rPIW7ebAqDL4ORIEcQ+yw3m4+TYBBtfSBixuhfeOFI5eGtUtf qYeDiK8lBag8UbjmeBzMiuSHKl6erZV6BT45lF1oSCe79ilN+tcU0V3p635jyBHmxM3aJKQ4glGlG OKZzLJ8G2erqWsrf2aA4epl8pA9vV1Oi9Jzfk0s7rqDuURtADQd0VDPezmrJFfm1r8kA7qSCMggkK gfnnRF7gx1xW4dgrj5ZvcaI/RCLXNQGJd7rkgypXjmzqA9pA1cJTJYiSn/DueXug1r0XTO3QSNpkI vULNzAnA==; Received: from authenticated user by zero.zsh.org with local id 1l7riO-0005iG-5W; Fri, 05 Feb 2021 03:23:24 +0000 Authentication-Results: zsh.org; iprev=pass (mail-oi1-f171.google.com) smtp.remote-ip=209.85.167.171; dkim=pass header.d=brasslantern-com.20150623.gappssmtp.com header.s=20150623 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none Received: from mail-oi1-f171.google.com ([209.85.167.171]:41975) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1l7rhv-0005KH-0o; Fri, 05 Feb 2021 03:22:55 +0000 Received: by mail-oi1-f171.google.com with SMTP id v193so681477oie.8 for ; Thu, 04 Feb 2021 19:22:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=E6VmHipJztLQOR81MVegn6U52OfrYeCgJPvHUazVsh4=; b=gqIrU1A9gY7Yck+y+K3w62ZXQieHqTXgSQAvHITbB5voljP9UXwUAvo1n/YiTVwGzN EF4dUvUR2r7xiBbUwn4UoXTWN92k+vVI1Jk6tesLNSRQOX0WCpngIb61cGyc8B7PRbon vSe8H/m9SFIGcxVQIwieQWStc8bwQqF0Hs8lyPf0uDaNM6QMxCQtN4B0B2YHp1Qxp2gY wh3Ww45/EOtcsMvstxeYAOZLPBdRFow4okSerb4d8BgVxY/U4SkAHrd7H6bEv4KWlAv7 Zsz7B2xznh+YUsgxCIHkJeDRCvIsH8CIZpFEQfjmH2CW+tvDDJyMmCqoA+FDueKDUypf sDAA== 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=E6VmHipJztLQOR81MVegn6U52OfrYeCgJPvHUazVsh4=; b=LC9djgDm75BNtz9MS8cWMIULR9IbwlF6ymNvmbqk8E566VmygspwEVx5CGx3EqGBFU Ex9BSrvThGWMyShSDpU3S3QiLqnRVOtmHavSCK/NIm68Ki4Javc/KCuPo4O+tK1VanWd uuAJqU329h9xIJxa5A4qzSod6lXUf4Cw07TAjGQo/xOQoYjo0ZZN310A9ZlD/hXLoNpW Ns91fGxok0rQ4mA3g2L1u1xr8bRiGRhiTQSxOxJt5ot2sZlTrFJxNRbtIUqdtb+PKY+M wptFwFzIO4sbYS4YSzJoRW+aDRVpCNR8QjLSrZ3FEOTI+6ROKVEESxCFOrtoFZZOfvTq qfVg== X-Gm-Message-State: AOAM530R6OfoYwJ7psBG4QmI37n6rt4ymbIakI2tkGgNmbFbGv+fmyzM isXtOor7ikdnOuMZmwrZb2C5/QaRtzvpsKOoYyjNQg== X-Google-Smtp-Source: ABdhPJwNkzKDmWu3t5Yr6Km1wHSwdR9OIkgJErWfeKNx8iGnEFM92v7WUz+9OdlbCFJioDwKUe/vjJEsffZrRMP9SqI= X-Received: by 2002:aca:72ce:: with SMTP id p197mr1816058oic.173.1612495373824; Thu, 04 Feb 2021 19:22:53 -0800 (PST) MIME-Version: 1.0 References: <52dba8e4-2538-7c96-ecd5-66e017ab2b8e@eastlink.ca> <36596ab3-14b6-da57-e40b-3e66d9ffbb5a@eastlink.ca> In-Reply-To: From: Bart Schaefer Date: Thu, 4 Feb 2021 19:22:42 -0800 Message-ID: Subject: Re: array with newlines preserved as literal text To: Ray Andrews Cc: Zsh Users Content-Type: text/plain; charset="UTF-8" X-Seq: 26460 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: On Thu, Feb 4, 2021 at 1:55 PM Ray Andrews wrote: > > Isn't 'tail' the normal term for whatever follows a command? I learned > it as 'command tail' back in the day. I've never called what I think you mean anything but the "arguments" or "argument list". Unless "tail" means more than that. > Anyway, more fiddling: I added " print -lr $@ " to my 'preexec()' and, > mirabile dictu, it seems to capture input exactly as typed: "Exactly as typed" is going to include the entire (possibly multi-line, pipelined, etc.) command input, not just one command. How much of that is the "tail"? > noglob _g '*$1*' # Why the duplication? RTM? Preexec gets three strings in $@. $1 is the string seen by the history mechanism $2 is is a single-line summary of the command $3 contains the full text that is being executed Note, $1 will be empty when history is disabled.