From: "Peter V. Saveliev" <peet@eltel.net> To: sisyphus@altlinux.ru Subject: Re: [sisyphus] Re: bash 2 Date: Thu, 17 Oct 2002 07:21:15 +0400 Message-ID: <20021017072115.315691ae.peet@eltel.net> (raw) In-Reply-To: <20021017021051.GA32652@homestead.turbinal.org> On Thu, 17 Oct 2002 06:10:51 +0400 at@turbinal.org wrote: <skip /> > Увы, мы имеем дело с глюкавым софтом. Интереснее всего это проявляется в > zsh: > > $ echo 123 | P=$(cat) > cat: -: Input/output error > $ > > Зачем зишелл отыскал дэш там, где его нет, и почему, к тому же, не смог > правильно открыть пайп, я не понимаю. здесь: дэш = STD(IO|OUT), в силу моего разумения. А что, если не секрет, вы хотите от этой конструкции? Этого? bash: [peet@admin2 peet]$ echo 123 | (P=`cat` && echo ">$P<") >123< [peet@admin2 peet]$ echo 123 | (P=$(cat) && echo ">$P<") >123< zsh: peet@admin2 ~ $ echo 123 | (P=`cat` && echo ">$P<") >123< peet@admin2 ~ $ echo 123 | (P=$(cat) && echo ">$P<") >123< Или я не то понял? Если так, то "глюкавость софта" несколько преувеличена... Хотя и непривычно, что zsh _требует_ подшелла для такой подстановки, но мало ли - фича, на мой взгляд, причем из полезных. Если посмотрите, то в баше без подшелла только _ошибки_ не будет, а $P все равно останется [ -z ] :))) [peet@admin2 peet]$ echo 123 | P=`cat` && echo ">$P<" >< Так что по мне уж лучше ошибка, чем молчаливое недоумение. -- Sincerely, Peter V. Saveliev E-mail: peet@eltel.net Jabber: peet@jabber.ru
prev parent reply other threads:[~2002-10-17 3:21 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2002-10-15 19:04 [sisyphus] " at 2002-10-17 1:03 ` [sisyphus] " at 2002-10-17 1:16 ` Serge Pavlovsky 2002-10-17 2:10 ` at 2002-10-17 2:44 ` Serge Pavlovsky 2002-10-17 5:01 ` at 2002-10-17 3:21 ` Peter V. Saveliev [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20021017072115.315691ae.peet@eltel.net \ --to=peet@eltel.net \ --cc=sisyphus@altlinux.ru \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
ALT Linux Sisyphus discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \ sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru public-inbox-index sisyphus Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.sisyphus AGPL code for this site: git clone https://public-inbox.org/public-inbox.git