zsh-users
 help / color / mirror / code / Atom feed
* Re: How to trigger the death of zsh(3.0.5)
@ 1998-10-08 19:26 Rob Windsor
  0 siblings, 0 replies; 14+ messages in thread
From: Rob Windsor @ 1998-10-08 19:26 UTC (permalink / raw)
  To: Mircea Damian; +Cc: zsh-users

I did blather:

> Verily did Mircea Damian write:

>> 1)
>>  I posted a while ago a message about the "disappearing zsh".
>>  I'm still using zsh-3.0.5(the one which comes with slackware 3.5) and I
>> found a way to trigger the death of zsh:
>>  I'm doing a backward-i-search(Ctrl-r) for "ls"(without quotes) and
>>  instead of pressing enter I'm hitting Ctrl-C(which is interrupt key for
>>  my terminal) so he prompt for search is disappearing. Then it's enough
>>  to type "ls", enter and the shell is dead.

>> My machine is linux-2.0.33 on a ix86 architecture(P200) with slackware 3.5.

> I can reproduce this bug on Solaris-2.6/sparc, SunOS 4.1.3_U1/sparc, and
> NetBSD-1.3.2/i386.

>> Here is the /etc/zprofile(which is linked to /etc/zshrc):

> [...]

>> setopt histignoredups histignorespace nobeep autocd autolist nonomatch
>> appendhistory nobgnice correctall histnostore listtypes

> I removed my .zshenv (no other zsh files) and went through my configuration
> line-by-line (option-by-option) to determine which one was consistently
> killing off my shell.  I found:

> ====
> : wst103:~; telnet localhost
> Trying 127.0.0.1...
> Connected to localhost.
> Escape character is '^]'.


> SunOS 5.6

> login: windsor
> Password: 
> Last login: Thu Oct  8 13:47:59 from localhost
> wst103% setopt prompt_subst
> (C-r, ls, C-c)
> wst103% ls
> Connection closed by foreign host.
> ====

> But I couldn't accurately reproduce the bug with your list of setopts, just
> "prompt_subst" (which you don't have listed).

Oh, one other addition to this:

If you use C-g (emacs "abort" keybinding instead of terminal INTR), your
shell doesn't blow out.

-- Rob
----------------------------------------
Internet: windsor@warthog.com
Life: Rob@Carrollton.Texas.USA.Earth

The weather is here, wish you were beautiful.


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-12 17:22                   ` Bart Schaefer
@ 1998-10-13  9:02                     ` Mircea Damian
  0 siblings, 0 replies; 14+ messages in thread
From: Mircea Damian @ 1998-10-13  9:02 UTC (permalink / raw)
  To: Bart Schaefer, zsh-users

On Mon, Oct 12, 1998 at 10:22:12AM -0700, Bart Schaefer wrote:
<snip>
> My guess is that it's sending ESC Ctrl-y (as for the console).  Ctrl-v
> quotes the ESC, but then Ctrl-y executes "yank" which inserts nothing
> because the kill buffer is empty.
> 
Checked that and you're right! It executes whatever \Cy is...


Are there any plans for a new development version of zsh?

-- 
Mircea Damian
Network Manager
dmircea@roedu.net, dmircea@lbi.ro, dmircea@kappa.ro
MD65-RIPE, MD2225, MD1-6BONE
Phone: +40-1-4115246


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-12 16:40                 ` Mircea Damian
@ 1998-10-12 17:22                   ` Bart Schaefer
  1998-10-13  9:02                     ` Mircea Damian
  0 siblings, 1 reply; 14+ messages in thread
From: Bart Schaefer @ 1998-10-12 17:22 UTC (permalink / raw)
  To: Mircea Damian, zsh-users

On Oct 12,  7:40pm, Mircea Damian wrote:
} Subject: Re: How to trigger the death of zsh(3.0.5)
}
} > Alt-y should generate one 8-bit character for the \C\My binding to work
} > 
} > Anytime a key generates a two- character or longer sequence, you have to
} > spell it out explicitly in the bindkey command.
}
} I'm using Xmodmap for xterm, but shouldn't the linux console be ok?

I don't know very much about how the linux console works.  A quick test
on my machine shows the console emitting ESC Ctrl-y for Ctrl-Alt-y, which
fits what you described, but I don't know why that's the case.

} If you rely on generating 8-bit sequences then if I would use a plain
} terminal(of course I won't do that :-)) which is not able to generate 8-bit
} chars what would happen? IMHO the best choice here is to make an option to
} swap between the two types.

Zsh does this with two sets of key bindings (keymaps).  If your terminal
sends real 8-bit bytes when the Alt or Meta keys are held down, then you
should use "bindkey -m" to enable the default meta-bindings.  (I forget
whether there's some other way to automatically enable that keymap, and
keybinding stuff has changed somewhat in 3.1.4.)

If your terminal doesn't send 8 bits (including if your stty settings
strip to 7 bits, which might happen e.g. on dialups) then you should not
use any of the meta-bindings.

} But still why \Cv \C\My gives me only an ESC ???

My guess is that it's sending ESC Ctrl-y (as for the console).  Ctrl-v
quotes the ESC, but then Ctrl-y executes "yank" which inserts nothing
because the kill buffer is empty.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-12 14:53               ` Bart Schaefer
@ 1998-10-12 16:40                 ` Mircea Damian
  1998-10-12 17:22                   ` Bart Schaefer
  0 siblings, 1 reply; 14+ messages in thread
From: Mircea Damian @ 1998-10-12 16:40 UTC (permalink / raw)
  To: Bart Schaefer, zsh-users

On Mon, Oct 12, 1998 at 07:53:20AM -0700, Bart Schaefer wrote:
> On Oct 9,  9:29pm, Mircea Damian wrote:
> } Subject: Re: How to trigger the death of zsh(3.0.5)
> }
> } I think that the right one is "^[\x19". Though if I type \Cv \My the echo
> } is:
> } (escape y)
> } which makes me to belive that my alt key is working ok (by prefixing the
> } key with an escape char).
> 
> Alt-y should generate one 8-bit character for the \C\My binding to work
> correctly.  On my system Alt-y is \371 (ù), and Ctrl-Alt-y is \231 (™).
> 
> Anytime a key generates a two- character or longer sequence, you have to
> spell it out explicitly in the bindkey command.  I'm -guessing- that you
> use xterm mappings to get ESC y from Alt-y, but that you haven't made a
> mapping for Ctrl-Alt-y, and that therefore xterm sends plain y on that
> combination.
Yes you are right, I'm using Xmodmap for xterm, but shouldn't the linux
console be ok?

Anyway I can trick the last one with "loadkeys" but I don't think that this
the best option.

If you rely on generating 8-bit sequences then if I would use a plain
terminal(of course I won't do that :-)) which is not able to generate 8-bit
chars what would happen? IMHO the best choice here is to make an option to
swap between the two types.

But still why \Cv \C\My gives me only an ESC ???

-- 
Mircea Damian
Network Manager
dmircea@roedu.net, dmircea@lbi.ro, dmircea@kappa.ro
MD65-RIPE, MD2225, MD1-6BONE
Phone: +40-1-4115246


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-09 18:29             ` Mircea Damian
@ 1998-10-12 14:53               ` Bart Schaefer
  1998-10-12 16:40                 ` Mircea Damian
  0 siblings, 1 reply; 14+ messages in thread
From: Bart Schaefer @ 1998-10-12 14:53 UTC (permalink / raw)
  To: Mircea Damian, zsh-users

On Oct 9,  9:29pm, Mircea Damian wrote:
} Subject: Re: How to trigger the death of zsh(3.0.5)
}
} I think that the right one is "^[\x19". Though if I type \Cv \My the echo
} is:
} (escape y)
} which makes me to belive that my alt key is working ok (by prefixing the
} key with an escape char).

Alt-y should generate one 8-bit character for the \C\My binding to work
correctly.  On my system Alt-y is \371 (ù), and Ctrl-Alt-y is \231 (™).

Anytime a key generates a two- character or longer sequence, you have to
spell it out explicitly in the bindkey command.  I'm -guessing- that you
use xterm mappings to get ESC y from Alt-y, but that you haven't made a
mapping for Ctrl-Alt-y, and that therefore xterm sends plain y on that
combination.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-09 16:17           ` Bart Schaefer
@ 1998-10-09 18:29             ` Mircea Damian
  1998-10-12 14:53               ` Bart Schaefer
  0 siblings, 1 reply; 14+ messages in thread
From: Mircea Damian @ 1998-10-09 18:29 UTC (permalink / raw)
  To: Bart Schaefer, zsh-users

> 	bindkey -s '\e1\e.' '\e-\e1\e.'

:-)
That happened first time ... but I figured it out.

> Are you doing (hold down Ctrl, hold down Alt, tap Y) or are you doing
> (tap ESC, hold down Ctrl, tap Y)?  The binding I gave was for the first
> of those, and does not also cause the second one to be bound.  You need
> to also do
> 
> 	bindkey '\e\Cy' insert-last-word
> 
> to get the ESC prefix to work.
It tried both(of course trying to do \Cv ESC \Cy is not such a good ideea
because ESC will be shown and \Cy will be interpreted as a command(if it is
binded)) and the echo is
^[

I think that the right one is "^[\x19". Though if I type \Cv \My the echo
is:
^[y
which makes me to belive that my alt key is working ok(by prefixing the
key with an escape char).

I'm puzzled :)

-- 
Mircea Damian
Network Manager
dmircea@roedu.net, dmircea@lbi.ro, dmircea@kappa.ro
MD65-RIPE, MD2225, MD1-6BONE
Phone: +40-1-4115246


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-09  4:43         ` Mircea Damian
@ 1998-10-09 16:17           ` Bart Schaefer
  1998-10-09 18:29             ` Mircea Damian
  0 siblings, 1 reply; 14+ messages in thread
From: Bart Schaefer @ 1998-10-09 16:17 UTC (permalink / raw)
  To: Mircea Damian, zsh-users

On Oct 9,  7:43am, Mircea Damian wrote:
} Subject: Re: How to trigger the death of zsh(3.0.5)
}
} > You can do `ESC - ESC 1 ESC .' to negate the digit, in which case zsh
} > counts from the beginning.
} 
} I think that a temporary _ugly_ fix is to bind the keys for some exact
} cases(5 or 6 arguments). This will "fix" their request... but I repeat it's
} ugly.

Be very careful not to introduce a loop.  You can't, for example, do

	bindkey -s '\e1\e.' '\e-\e1\e.'

as the ESC 1 ESC . in the expansion will again match the key binding and
repeat the expansion.

} > More specifically than that, I can't tell.  If you type \Cv \C\My, what
} > do you see?  If you see ^Y, then your alt or meta key isn't working,
} > which could explain the beeping.
} 
} Something strange happens here.
} If I type \Cv \C\My I only get the ESC character('^[')

Are you doing (hold down Ctrl, hold down Alt, tap Y) or are you doing
(tap ESC, hold down Ctrl, tap Y)?  The binding I gave was for the first
of those, and does not also cause the second one to be bound.  You need
to also do

	bindkey '\e\Cy' insert-last-word

to get the ESC prefix to work.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-08 21:34       ` Bart Schaefer
@ 1998-10-09  4:43         ` Mircea Damian
  1998-10-09 16:17           ` Bart Schaefer
  0 siblings, 1 reply; 14+ messages in thread
From: Mircea Damian @ 1998-10-09  4:43 UTC (permalink / raw)
  To: Bart Schaefer; +Cc: zsh-users

> Ah.  There's really no way to fix that one.  Even in 3.1.4 where you can
> make your own new zle functions, support for using the digit-argument
> prefixes is not yet up to snuff.
> 
> You can do `ESC - ESC 1 ESC .' to negate the digit, in which case zsh
> counts from the beginning.  You can even do `ESC - ESC 0 ESC .' to get
> the command name.
> 
> Or you can do `! : x TAB' where x is the number of the word you want,
> e.g. !:2 for the second word.

I think that a temporary _ugly_ fix is to bind the keys for some exact
cases(5 or 6 arguments). This will "fix" their request... but I repeat it's
ugly.


> Yes, change the value of the WORDCHARS variable.  I use
> 
> 	WORDCHARS='*?_-.[]~\!#$%^(){}<>'
> 
> The only drawback is that it also affects transpose-words, which is
> sometimes not what you'd like.

It's just perfect. Thanks!


> 
> More specifically than that, I can't tell.  If you type \Cv \C\My, what
> do you see?  If you see ^Y, then your alt or meta key isn't working,
> which could explain the beeping.

Something strange happens here.
If I type \Cv \C\My I only get the ESC character('^[') but the
lines(strace) bellow shows that it reads more when I press \C\My. The
behaviour is the same if I use xterm or linux console:

read(10, "\33", 1)                      = 1          //ESC
read(10, "\31", 1)                      = 1          //\Cy
select(11, [10], NULL, NULL, {0, 0})    = 0 (Timeout)
read(10, "\26", 1)                      = 1          //\Cv
read(10, "\33", 1)                      = 1          //ESC
select(11, [10], NULL, NULL, {0, 0})    = 1 (in [10], left {0, 0})
read(10, "\31", 1)                      = 1          //\Cy
select(11, [10], NULL, NULL, {0, 0})    = 0 (Timeout)
write(10, "^[", 2)                      = 2          //??! why only ^[
read(10,



Thank you for your prompt answers!

-- 
Mircea Damian
Network Manager
dmircea@roedu.net, dmircea@lbi.ro, dmircea@kappa.ro
MD65-RIPE, MD2225, MD1-6BONE
Phone: +40-1-4115246


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-08 19:49     ` Mircea Damian
@ 1998-10-08 21:34       ` Bart Schaefer
  1998-10-09  4:43         ` Mircea Damian
  0 siblings, 1 reply; 14+ messages in thread
From: Bart Schaefer @ 1998-10-08 21:34 UTC (permalink / raw)
  To: Mircea Damian; +Cc: zsh-users

On Oct 8, 10:44pm, Mircea Damian wrote:
} Subject: Re: How to trigger the death of zsh(3.0.5)
}
} On Thu, Oct 08, 1998 at 11:58:31AM -0700, Bart Schaefer wrote:
} > That function is bound by default to ESC . and ESC _ in zsh.  Rebinding to
} > the bash equivalent is as easy as:
} > 
} > 	bindkey '\C\My' insert-last-word
} 
} Ok but how about the order? 
} ESC 1 ESC . will give the last argument when in bash it means the first
} one.

Ah.  There's really no way to fix that one.  Even in 3.1.4 where you can
make your own new zle functions, support for using the digit-argument
prefixes is not yet up to snuff.

You can do `ESC - ESC 1 ESC .' to negate the digit, in which case zsh
counts from the beginning.  You can even do `ESC - ESC 0 ESC .' to get
the command name.

Or you can do `! : x TAB' where x is the number of the word you want,
e.g. !:2 for the second word.

} Q: Is there a way to set the separator(or a list of separators) when
} doing backward-kill-word?

Yes, change the value of the WORDCHARS variable.  I use

	WORDCHARS='*?_-.[]~\!#$%^(){}<>'

The only drawback is that it also affects transpose-words, which is
sometimes not what you'd like.

On Oct 8, 10:49pm, Mircea Damian wrote:
} Subject: Re: How to trigger the death of zsh(3.0.5)
}
} What I meant is that if I press  \C\My I receive a
} beep instead of the last argument..

There are a couple of reasons why this might happen.  One is that if
you repeat insert-last-word without doing any other typing, it tries
to insert the last word from successively farther back in the history.
E.g.:

zsh[1] echo one two
one two
zsh[2] echo three four
three four
zsh[3] echo <ESC .>
zsh[3] echo four<ESC .>
zsh[3] echo two<ESC .>
(zsh beeps, ran out of history)
zsh[3] echo

More specifically than that, I can't tell.  If you type \Cv \C\My, what
do you see?  If you see ^Y, then your alt or meta key isn't working,
which could explain the beeping.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-08 19:44   ` Mircea Damian
@ 1998-10-08 19:49     ` Mircea Damian
  1998-10-08 21:34       ` Bart Schaefer
  0 siblings, 1 reply; 14+ messages in thread
From: Mircea Damian @ 1998-10-08 19:49 UTC (permalink / raw)
  To: Bart Schaefer; +Cc: zsh-users

This is not too clear... What I meant is that if I press  \C\My I receive a
beep instead of the last argument..

> Script started on Thu Oct  8 22:43:27 1998
> dmircea@secu:~% bindkey '\C\My' insert-last-word
> dmircea@secu:~% bindkey | grep insert-last-word
> "\M-^Y"	insert-last-word
> "^[."	insert-last-word
> "^[_"	insert-last-word
> dmircea@secu:~% exit
> 
> Script done on Thu Oct  8 22:44:00 1998
> 

-- 
Mircea Damian
Network Manager
dmircea@roedu.net, dmircea@lbi.ro, dmircea@kappa.ro
MD65-RIPE, MD2225, MD1-6BONE
Phone: +40-1-4115246


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-08 18:58 ` Bart Schaefer
@ 1998-10-08 19:44   ` Mircea Damian
  1998-10-08 19:49     ` Mircea Damian
  0 siblings, 1 reply; 14+ messages in thread
From: Mircea Damian @ 1998-10-08 19:44 UTC (permalink / raw)
  To: Bart Schaefer; +Cc: zsh-users

On Thu, Oct 08, 1998 at 11:58:31AM -0700, Bart Schaefer wrote:
> That function is bound by default to ESC . and ESC _ in zsh.  Rebinding to
> the bash equivalent is as easy as:
> 
> 	bindkey '\C\My' insert-last-word

Ok but how about the order? 
ESC 1 ESC . will give the last argument when in bash it means the first
one.

So I need to do something like insert the argument
n-x where n is the total number of words on the previous command(x is the
number after ESC).

Q: Is there a way to set the separator(or a list of separators) when doing backward-kill-word? For example if I'm typing:

% cd /usr/src^W
I would like to have
% cd /usr/
not 
% cd 
(this is also bash's behaviour)


PS: Maybe I'm too tired now but:

Script started on Thu Oct  8 22:43:27 1998
dmircea@secu:~% bindkey '\C\My' insert-last-word
dmircea@secu:~% bindkey | grep insert-last-word
"\M-^Y"	insert-last-word
"^[."	insert-last-word
"^[_"	insert-last-word
dmircea@secu:~% exit

Script done on Thu Oct  8 22:44:00 1998

-- 
Mircea Damian
Network Manager
dmircea@roedu.net, dmircea@lbi.ro, dmircea@kappa.ro
MD65-RIPE, MD2225, MD1-6BONE
Phone: +40-1-4115246


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-08 17:49 Mircea Damian
  1998-10-08 18:58 ` Bart Schaefer
@ 1998-10-08 19:15 ` Rob Windsor
  1 sibling, 0 replies; 14+ messages in thread
From: Rob Windsor @ 1998-10-08 19:15 UTC (permalink / raw)
  To: Mircea Damian; +Cc: zsh-users

Verily did Mircea Damian write:

> 1)
>  I posted a while ago a message about the "disappearing zsh".
>  I'm still using zsh-3.0.5(the one which comes with slackware 3.5) and I
> found a way to trigger the death of zsh:
>  I'm doing a backward-i-search(Ctrl-r) for "ls"(without quotes) and
>  instead of pressing enter I'm hitting Ctrl-C(which is interrupt key for
>  my terminal) so he prompt for search is disappearing. Then it's enough
>  to type "ls", enter and the shell is dead.

> My machine is linux-2.0.33 on a ix86 architecture(P200) with slackware 3.5.

I can reproduce this bug on Solaris-2.6/sparc, SunOS 4.1.3_U1/sparc, and
NetBSD-1.3.2/i386.

> Here is the /etc/zprofile(which is linked to /etc/zshrc):

[...]

> setopt histignoredups histignorespace nobeep autocd autolist nonomatch append
>history nobgnice correctall histnostore listtypes

I removed my .zshenv (no other zsh files) and went through my configuration
line-by-line (option-by-option) to determine which one was consistently
killing off my shell.  I found:

====
: wst103:~; telnet localhost
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.


SunOS 5.6

login: windsor
Password: 
Last login: Thu Oct  8 13:47:59 from localhost
wst103% setopt prompt_subst
(C-r, ls, C-c)
wst103% ls
Connection closed by foreign host.
====

But I couldn't accurately reproduce the bug with your list of setopts, just
"prompt_subst" (which you don't have listed).

-- Rob
----------------------------------------
Internet: windsor@warthog.com
Life: Rob@Carrollton.Texas.USA.Earth

The weather is here, wish you were beautiful.


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

* Re: How to trigger the death of zsh(3.0.5)
  1998-10-08 17:49 Mircea Damian
@ 1998-10-08 18:58 ` Bart Schaefer
  1998-10-08 19:44   ` Mircea Damian
  1998-10-08 19:15 ` Rob Windsor
  1 sibling, 1 reply; 14+ messages in thread
From: Bart Schaefer @ 1998-10-08 18:58 UTC (permalink / raw)
  To: Mircea Damian, zsh-users

On Oct 8,  8:49pm, Mircea Damian wrote:
} Subject: How to trigger the death of zsh(3.0.5)
}
}  I posted a while ago a message about the "disappearing zsh".
}  I'm still using zsh-3.0.5(the one which comes with slackware 3.5) and I
} found a way to trigger the death of zsh:
}  I'm doing a backward-i-search(Ctrl-r) for "ls"(without quotes) and instead
} of pressing enter I'm hitting Ctrl-C(which is interrupt key for my terminal)
} the prompt for search is disappearing. Then it's enough to type "ls",
} enter and the shell is dead.

A patch for this was posted to zsh-workers some while ago.  You can find
the article at:

	http://www.zsh.org/cgi-bin/mla/workers/bynum/4172

There's a related thread that explains what's going on, which you can find
by looking at:

	http://www.zsh.org/cgi-bin/mla/workers/bynum/4095

but you want the patch from 4172, not 4095.  It should apply OK to 3.0.5
even though the subject says 3.1.4.  (The above URLs are to HTML-ified
messages; you probably want to hit <http://www.zsh.org/mla/zsh-workers/>
and pick up the appropriate gzip'd tar file for patching.)

} 2)
} Another question: Is there any way to bind the keys the way they are in
} bash for "insert-last-word"? I'm trying to convince some other people to
} move to zsh but it seems that this is a big impediment for them.

That function is bound by default to ESC . and ESC _ in zsh.  Rebinding to
the bash equivalent is as easy as:

	bindkey '\C\My' insert-last-word

} 3)
} Why zsh is not able to run the script which comes with linux kernel
} scripts/patch-kernel? It seems that it is not passing the PATH enviroment

That's not very likely to be the problem.  More likely is that patch-kernel
is a bash script, and you're being bitten by something like SH_WORD_SPLIT
behavior.  You need to tell zsh to emulate sh when reading /bin/sh scripts.

} with a command like:
} 
} . scripts/patch-kernel

Ooo, ick.  Don't do that.  Script files are rarely intended to be read into
an interactive shell that way.  (Not never, but rarely, and surely not in
that particular case.)

} zsh scripts/patch-kernel

Try (from your login zsh):

	ARGV0=sh zsh scripts/patch-kernel

or just run patch-kernel with "sh" as was intended.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com


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

* How to trigger the death of zsh(3.0.5)
@ 1998-10-08 17:49 Mircea Damian
  1998-10-08 18:58 ` Bart Schaefer
  1998-10-08 19:15 ` Rob Windsor
  0 siblings, 2 replies; 14+ messages in thread
From: Mircea Damian @ 1998-10-08 17:49 UTC (permalink / raw)
  To: zsh-users



Hello,

1)
 I posted a while ago a message about the "disappearing zsh".
 I'm still using zsh-3.0.5(the one which comes with slackware 3.5) and I
found a way to trigger the death of zsh:
 I'm doing a backward-i-search(Ctrl-r) for "ls"(without quotes) and instead of
pressing enter I'm hitting Ctrl-C(which is interrupt key for my terminal) so
the prompt for search is disappearing. Then it's enough to type "ls",
enter and the shell is dead.


My machine is linux-2.0.33 on a ix86 architecture(P200) with slackware 3.5.

The strace output is available on request.

Here is the /etc/zprofile(which is linked to /etc/zshrc):

export PS1='%n@%m:%~%# '
export PATH=/usr/lib/teTeX/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/local/samba/bin:.
export HISTFILE=~/.history
export HISTSIZE=500
export LESSOPEN="|lesspipe.sh %s"
export LESS="-MMQ"
export SAVEHIST=500
export PAGER=less
export MIBS=ALL

setopt histignoredups histignorespace nobeep autocd autolist nonomatch appendhistory nobgnice correctall histnostore listtypes

# Home, End, Del for linux and xterm
bindkey "^[[1~" beginning-of-line
bindkey "^[[3~" delete-char
bindkey "^[[4~" end-of-line

ulimit -c 0

#ls colors
eval `dircolors -z`

#alias part
alias cls=clear
alias l='ls -lsa'
alias cp='cp -i'
alias mv='nocorrect mv -i'
alias s='screen'

#we are done
echo

--- end here ---

I have no personal rcfiles.


2)
Another question: Is there any way to bind the keys the way they are in
bash for "insert-last-word"? I'm trying to convince some other people to
move to zsh but it seems that this is a big impediment for them.
In bash if I type Ctrl-Alt-y it inserts the first argument of the previous
command(this can be done also with ESC Ctrl-y as two hits sequence). Of
course if this is preceded be a Alt-number(or ESC number) it will insert
the argument of the previous command with that number.


3)
Why zsh is not able to run the script which comes with linux kernel
scripts/patch-kernel? It seems that it is not passing the PATH enviroment
variable because it is not finding "gzip" or "bzip2"(I'm runing the script
with a command like:

. scripts/patch-kernel

or 

zsh scripts/patch-kernel
)


I would appreciate any help or hints.
Thank you,

-- 
Mircea Damian
Network Manager
dmircea@roedu.net, dmircea@lbi.ro, dmircea@kappa.ro
MD65-RIPE, MD2225, MD1-6BONE
Phone: +40-1-4115246


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

end of thread, other threads:[~1998-10-13  9:10 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-10-08 19:26 How to trigger the death of zsh(3.0.5) Rob Windsor
  -- strict thread matches above, loose matches on Subject: below --
1998-10-08 17:49 Mircea Damian
1998-10-08 18:58 ` Bart Schaefer
1998-10-08 19:44   ` Mircea Damian
1998-10-08 19:49     ` Mircea Damian
1998-10-08 21:34       ` Bart Schaefer
1998-10-09  4:43         ` Mircea Damian
1998-10-09 16:17           ` Bart Schaefer
1998-10-09 18:29             ` Mircea Damian
1998-10-12 14:53               ` Bart Schaefer
1998-10-12 16:40                 ` Mircea Damian
1998-10-12 17:22                   ` Bart Schaefer
1998-10-13  9:02                     ` Mircea Damian
1998-10-08 19:15 ` Rob Windsor

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