bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[OT] Re: how to start in "overwrite-mode"


From: Stephane CHAZELAS
Subject: [OT] Re: how to start in "overwrite-mode"
Date: Wed, 28 Oct 2009 07:38:47 +0000 (UTC)
User-agent: slrn/pre1.0.0-11 (Linux)

2009-10-27, 16:29(-04), Jim Lawson:
[...]
> I have a user we're trying to encourage to migrate from tcsh to bash,
> who is used to his shell starting up in overwrite mode (as opposed to
> the default Insert mode.)
>
> Long story short, while I can easily bind a key to the "overwrite-mode"
> readline function, I can't figure out how to make bind start up that way
> as I can't find an "overwrite" readline variable which I can manipulate.
>  And the user doesn't want to hit "Ins" every time he starts a shell.
>
> Anyone know how to do this?
[...]

Sorry, I don't know how to do it with bash, but here's a
solution for zsh (switching from tcsh to zsh might reveal
easier btw):

in ~/.zshrc, add:

zle-line-init() zle overwrite-mode
zle -N zle-line-init

To get back on topic, bash is the only Bourne-like shell that I
know that doesn't allow that function definition syntax above,
I've always wondered why.

-- 
Stéphane


reply via email to

[Prev in Thread] Current Thread [Next in Thread]