zsh-users
 help / color / mirror / code / Atom feed
* Strange effect under  3.1.1
@ 1997-02-03 11:19 Helmut Jarausch
  1997-02-03 12:50 ` Zefram
  0 siblings, 1 reply; 5+ messages in thread
From: Helmut Jarausch @ 1997-02-03 11:19 UTC (permalink / raw)
  To: Zoltan Hidvegi; +Cc: zsh-users


Hi,

I just noticed a very strange effect after having switched to 3.1.1 .
Please tell, what's going on here.
Thanks,
Helmut Jarausch.


I have a symbolic link   /bin/shell  ->  /bin/zsh

This script works as expected

With fileA
#!/bin/zsh
echo $ZSH_VERSION
echo $argv[-1]

fileA 1 2 3
prints (as expected)

3.1.1
3


BUT  with
fileB
#!/bin/shell
echo $ZSH_VERSION
echo $argv[2]

fileB 1 2 3
prints (not so expected)

3.1.1
[-1]               <====================== what's going on here ?



--
Helmut Jarausch
Lehrstuhl f. Numerische Mathematik
Institute of Technology
RWTH Aachen
D 52056 Aachen, Germany




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange effect under  3.1.1
  1997-02-03 11:19 Strange effect under 3.1.1 Helmut Jarausch
@ 1997-02-03 12:50 ` Zefram
  0 siblings, 0 replies; 5+ messages in thread
From: Zefram @ 1997-02-03 12:50 UTC (permalink / raw)
  To: Helmut Jarausch; +Cc: Z Shell users mailing list

Helmut Jarausch wrote:
>I have a symbolic link   /bin/shell  ->  /bin/zsh

When zsh is invoked as "shell" -- or anything else starting with "s" --
it emulates the POSIX shell.

-zefram


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange effect under  3.1.1
  1997-02-03 20:07 Zoltan Hidvegi
  1997-02-03 21:20 ` Zefram
@ 1997-02-03 22:12 ` Juergen Christoffel
  1 sibling, 0 replies; 5+ messages in thread
From: Juergen Christoffel @ 1997-02-03 22:12 UTC (permalink / raw)
  To: hzoli; +Cc: zsh-users

   From: Zoltan Hidvegi <hzoli@cs.elte.hu>
   Date: Mon, 3 Feb 1997 21:07:10 +0100 (MET)

   > When zsh is invoked as "shell" -- or anything else starting with "s" --
   > it emulates the POSIX shell.

   Yes.  I should have mentioned this change, sorry.  Now the emulation
   mode is determined after examining the first letter of the name used
   to invoke zsh.

Hmm, may I ask what's the rationale to use only the first letter to
make that decision? 

Just imagine a poor unsuspecting soul who links his zsh to something
like coolsh and then wonders what has happened to his shell... 

It shouldn't be too costly to compare the whole name after the last /
on startup, or would it?

	--jc


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange effect under  3.1.1
  1997-02-03 20:07 Zoltan Hidvegi
@ 1997-02-03 21:20 ` Zefram
  1997-02-03 22:12 ` Juergen Christoffel
  1 sibling, 0 replies; 5+ messages in thread
From: Zefram @ 1997-02-03 21:20 UTC (permalink / raw)
  To: Zoltan Hidvegi; +Cc: zsh-users

Zoltan Hidvegi wrote:
>If the first letter is c, csh emulation options are used,

Perhaps 't' (for tcsh) should also be added.

-zefram


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Strange effect under  3.1.1
@ 1997-02-03 20:07 Zoltan Hidvegi
  1997-02-03 21:20 ` Zefram
  1997-02-03 22:12 ` Juergen Christoffel
  0 siblings, 2 replies; 5+ messages in thread
From: Zoltan Hidvegi @ 1997-02-03 20:07 UTC (permalink / raw)
  To: zsh-users

> When zsh is invoked as "shell" -- or anything else starting with "s" --
> it emulates the POSIX shell.

Yes.  I should have mentioned this change, sorry.  Now the emulation
mode is determined after examining the first letter of the name used
to invoke zsh.  If the first letter is s or b zsh enters sh emulation
mode..  Perhaps p should be added to this list (some systems use psh
for POSIX shell).

If the first letter is k, ksh emulation is turen on.

If the first letter is c, csh emulation options are used, otherwise it
uses native mode.

Zoltan


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1997-02-03 22:25 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-02-03 11:19 Strange effect under 3.1.1 Helmut Jarausch
1997-02-03 12:50 ` Zefram
1997-02-03 20:07 Zoltan Hidvegi
1997-02-03 21:20 ` Zefram
1997-02-03 22:12 ` Juergen Christoffel

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).