zsh-workers
 help / color / mirror / code / Atom feed
From: Zoltan Hidvegi <hzoli@cs.elte.hu>
To: zefram@dcs.warwick.ac.uk (Zefram)
Cc: schaefer@nbn.com, zsh-workers@math.gatech.edu
Subject: Re: pushd
Date: Thu, 17 Oct 1996 00:28:22 +0200 (MET DST)	[thread overview]
Message-ID: <199610162228.AAA00459@hzoli.ppp.cs.elte.hu> (raw)
In-Reply-To: <5016.199610161810@stone.dcs.warwick.ac.uk> from Zefram at "Oct 16, 96 07:10:53 pm"

> Oh, what was the reasoning behind requiring "(UID=123; foo)" where
> "UID=123 foo" used to work?  I liked the exporting syntax.

It was the simplest way to handle special parameters.  If you say
parameter=value command the given environment variable is always set to
value even if it is a special parameter or integer or anything.  So now
UID=hzoli printenv UID says hzoli.  In case of UID it may net be the
desired behaviour but in some other cases this makes things simpler.  I
also liked the exporting syntax but I often tried to use that to a zsh
function or to a builtin which caused irreversibly lost privileges.
Offtopic but note that USERNAME is much more secure as it now executes
initgroups() as well similarily to su username (this is new, zsh-3.0.0 does
not do that).

A somewhat related question:

% ksh
$ readonly foo=foo    
$ foo=bar printenv foo
ksh: foo: is read only

% zsh
% readonly foo=foo    
% foo=bar printenv foo
bar

The current bash version behaves similarily but I talked to the bash
maintainer and he thinks that the ksh behaviour is the correct one and
bash-2.0 will now allow this.  Similar question:

% ksh
$ typeset -i i=12
$ i=foo printenv i
0

Zsh prints foo here.  That's why UID=798 command does not work.

Zoltan


  parent reply	other threads:[~1996-10-16 23:34 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-10-11 12:34 pushd Peter Stephenson
1996-10-11 13:01 ` pushd Vinnie Shelton
1996-10-11 15:13   ` pushd Peter Whaite
1996-10-11 19:53 ` pushd Bart Schaefer
1996-10-15 12:45   ` pushd Peter Stephenson
1996-10-15 17:08     ` pushd Bart Schaefer
1996-10-15 17:34       ` pushd Zoltan Hidvegi
1996-10-16  5:38         ` pushd Bart Schaefer
1996-10-16  8:42           ` pushd Zefram
1996-10-16 17:36             ` pushd Bart Schaefer
1996-10-16 18:10               ` pushd Zefram
1996-10-16 21:16                 ` pushd Bart Schaefer
1996-10-17 13:22                   ` pushd Anthony Heading
1996-10-17 13:47                     ` pushd Peter Stephenson
1996-10-17 17:01                     ` pushd Bart Schaefer
1996-10-16 22:28                 ` Zoltan Hidvegi [this message]
1996-10-16 12:42           ` pushd Peter Stephenson
1996-10-15 18:45       ` pushd Anthony Heading
1996-10-18 13:14 pushd Ray Van Tassle-CRV004

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=199610162228.AAA00459@hzoli.ppp.cs.elte.hu \
    --to=hzoli@cs.elte.hu \
    --cc=schaefer@nbn.com \
    --cc=zefram@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).