zsh-workers
 help / color / mirror / code / Atom feed
From: Zoltan Hidvegi <hzoli@cs.elte.hu>
To: A.Main@dcs.warwick.ac.uk (Zefram)
Cc: zsh-workers@math.gatech.edu
Subject: Re: <> redirection operator (was: zsh.texi)
Date: Mon, 17 Jun 1996 15:10:29 +0200 (MET DST)	[thread overview]
Message-ID: <199606171310.PAA01359@bolyai.cs.elte.hu> (raw)
In-Reply-To: <12801.199606161323@stone.dcs.warwick.ac.uk> from Zefram at "Jun 16, 96 02:23:14 pm"

> >I agree with that but I'm afraid that this change will break many scripts.
> >But it would be definitely simpler and cleaner, and the documentation would
> >be much simpler and less confusing.
> 
> How often do you use numerical globbing?  I've only ever used it
> interactively.  It wouldn't be the first time we've changed behaviour,
> and the change required to scripts is trivial.

I decided: in beta21, <> will always do redirection.

> And regarding the &> redirection you mentioned: I think this is a bad
> idea.  It's not POSIX conformant (consider `a &> b c`), and it's not

Yes, a &> b c will work differently from what POSIX requires but a & > b c
will be OK.  I do not think that there is any script which contains
adjacent & and >.

> really necessary.  It is possible to redirect to a file called "-" by
> doing `>& ./-`.

The biggest problem is when you use parameter expansion.  When you write
>& $foo you cannot tell in advance wether the output will be closed or if
it goes to a file, or to an other file descriptor or to the coprocess.

Implementing &> is very simple and I do not think that it conflicts with
any scripts (and a portable script which expects POSIX behaviour should not
use &> anyway since bash uses it for redirectiog standard output and
error which means that such a script will not work under Linux).

Zoltan



  reply	other threads:[~1996-06-17 13:29 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-06-10 15:52 zsh.texi Clive Messer
1996-06-10 16:17 ` zsh.texi Hrvoje Niksic
1996-06-10 16:39 ` zsh.texi Zoltan Hidvegi
1996-06-10 19:01   ` zsh.texi Clive Messer
1996-06-13  5:25 ` zsh.texi Mark Borges
1996-06-13  6:26   ` zsh.texi Bart Schaefer
1996-06-13 13:49     ` zsh.texi Clive Messer
1996-06-13 15:30       ` zsh.texi Bart Schaefer
1996-06-13 17:19       ` zsh.texi Mark Borges
1996-06-13  6:55   ` zsh.texi Bart Schaefer
1996-06-15  1:53     ` zsh.texi Zoltan Hidvegi
1996-06-15  7:44       ` zsh.texi Zefram
1996-06-15 22:08         ` <> redirection operator (was: zsh.texi) Zoltan Hidvegi
1996-06-16 13:23           ` Zefram
1996-06-17 13:10             ` Zoltan Hidvegi [this message]
1996-06-17 13:56               ` Peter Stephenson
1996-06-17 15:16                 ` Peter Whaite
1996-06-13  7:18   ` zsh.texi Bart Schaefer

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=199606171310.PAA01359@bolyai.cs.elte.hu \
    --to=hzoli@cs.elte.hu \
    --cc=A.Main@dcs.warwick.ac.uk \
    --cc=zsh-workers@math.gatech.edu \
    /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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).