From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from primenet.com.au (ns1.primenet.com.au [203.24.36.2]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id d3bad68d for ; Wed, 13 Nov 2019 13:31:14 +0000 (UTC) Received: (qmail 19441 invoked by alias); 13 Nov 2019 13:30:54 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: List-Unsubscribe: X-Seq: 24425 Received: (qmail 2529 invoked by uid 1010); 13 Nov 2019 13:30:54 -0000 X-Qmail-Scanner-Diagnostics: from mail-qv1-f54.google.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.102.0/25628. spamassassin: 3.4.2. Clear:RC:0(209.85.219.54):SA:0(-2.0/5.0):. Processed in 0.810063 secs); 13 Nov 2019 13:30:54 -0000 X-Envelope-From: oguzismailuysal@gmail.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _netblocks.google.com designates 209.85.219.54 as permitted sender) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=Gk8EK5x7f3awz6xtnRddoVths/VtcadzRKWgtAgNxSA=; b=BfEru/3mA6+swmAStfuzzMC6KaKuBOtMp1n1LAiCWLfp5gmkHpoM2Icy8oNfzF7T8b QOa3sQ77EbGxu8xJw8+Yo9gMwHY3uRATVz8KDRLWR7rcDArUBauicuKo4T49z41QZ+Zk UUaEGyps0H4hvTGSh49Xcbi5kSqQSNGuxmXCqH99QZg9ehIG6TsNThLl0AAQQFX8RBx2 RPkM7OoUYVTcRSnhI4s/E34v3Cf9EvM4DF3dLsavAsa6vLhwtFHGTGH3EIxhIB26yg42 3+jPFTsh+nrUOLV7SLeVBqy5IodwD5DmWcNEzYlWrcNMm7l7JEqFBK3TvwoOUw/B/v2B VlTA== 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; bh=Gk8EK5x7f3awz6xtnRddoVths/VtcadzRKWgtAgNxSA=; b=bACRoQbPUtuEIyhTB+zvE2yAAESkmPeGEjGF/+QJR8ArevNFY1DEjvGE04H10AQHrW tqc2j+LzEoXG5Wh0Dz5GogSrKu7FOJ68MDxK0nRHVXkqhmgYTXq8fRvIh4rTJGOLBR0i /kbGNG8HO2bDfKFZjt1Litu69wRtdQx+ofa+XVdbO577c+6h8W4262hwrqLjyun+in+I NA1N6I4+rLy8C0WIdUY7eXimpi3idXwsQKtUVNLvz6ncbz6eAB6s0BWyxRrgOg9snuEp HjlKmhlI/XwYfkZg7lo+M26fw1Q2r2LntTp3Hk22ZVXt61sbKfAxPHu52hUB2h+N7R1A Tr1A== X-Gm-Message-State: APjAAAVGftcSbU/gnjWUCnrElZEFHCVP1kik5MpIGpYLwOFLEq9QxgWL 79HB/oHqZpkL3sjLuw6a6WqyQa/o8qiN2NIoidtGTNdVSg0= X-Google-Smtp-Source: APXvYqxIE3ZSgjTBEXcYA+2rd5vAVr0kRedvEz04P7MPywC3yWTMd4/JgyGlR3tlWl4ArVEc1C5zWyas3La8x62MGF0= X-Received: by 2002:a05:6214:8e5:: with SMTP id dr5mr2680060qvb.79.1573651819659; Wed, 13 Nov 2019 05:30:19 -0800 (PST) MIME-Version: 1.0 References: <20191113130023.n7lgi2vov44kkjfl@chaz.gmail.com> In-Reply-To: <20191113130023.n7lgi2vov44kkjfl@chaz.gmail.com> From: =?UTF-8?B?T8SfdXo=?= Date: Wed, 13 Nov 2019 16:30:06 +0300 Message-ID: Subject: Re: substituted command won't inherit stdin in pipeline To: =?UTF-8?B?T8SfdXo=?= , zsh-users@zsh.org Content-Type: multipart/alternative; boundary="000000000000b6059305973a5dc5" --000000000000b6059305973a5dc5 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Nov 13, 2019 at 4:00 PM Stephane Chazelas < stephane.chazelas@gmail.com> wrote: > 2019-11-13 12:52:20 +0300, O=C4=9Fuz: > > On all sh implementations I have, this command > > > > echo foo | echo "$(cat)" > > > > prints 'foo', except for zsh, it hangs instead. From that I gather cat > > doesn't inherit echo's stdin, and it waits for input. > [...] > > Not exactly what happens in that the expansions in the arguments > of the commands in the pipeline are performed in the parent, > from left to right, not in the processes that run the > individualy pipe components (also note that the right-most pipe > component is run in the current shell anyway, like in ksh93, > unlike in bash). > [...] Now I'm confused. Is this what standard says, or what zsh does? --000000000000b6059305973a5dc5--