Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

RE: New user questions

> Well thanks everyone for all the help.  Just about everything
> is working
> sweetly (better than the old shell, actually).

Have you had any doubts? :-)

> A few more observations:
> - The zshbuiltins manpage doesn't cover 'bindkey'

This is in modules section (Zle module). But, yes, I never liked this.
Users are not supposed to know, if command is implemented in core or

man zshmodules

> - History-search-backward could be improved.  In this example it is
> bound to ESC:
> prompt> echo foo
> prompt> echo bar
> prompt> echo f<ESC>
> This will then match 'echo bar'.  Would be more sensible to
> match 'echo
> foo'?

There is history-beginning-search-(backward|forward) that should do that

     Search backward in the history for a line beginning with the
     current line up to the cursor.  This leaves the cursor in its
     original position.

> Question: How do I, within .zshrc, simply erase _all_ preexisting
> bindings and start afresh?  I've tried everything.
> pwold011:/home/morton> bindkey -l
> .safe
> emacs
> main
> vicmd
> viins
> pwold011:/home/morton> bindkey -D emacs vicmd viins
> pwold011:/home/morton> bindkey -l
> .safe
> main
> pwold011:/home/morton> bindkey -D main
> No such keymap `main'

bor@itsrm2% bindkey -N foo .safe
bor@itsrm2% bindkey -A foo main
bor@itsrm2% bindkey -L
bindkey -R "^@"-"^I" self-insert
bindkey "^J" accept-line
bindkey -R "^K"-"^L" self-insert
bindkey "^M" accept-line
bindkey -R "^N"-"\M-^?" self-insert

These are the minimum - you want to be able to at least enter
characters. If you simply create an *empty* map and assign it to main -
no input will be possible at all.


Messages sorted by: Reverse Date, Date, Thread, Author