Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: End of line instead of beginning of line
- X-seq: zsh-users 14502
- From: David Evans <David.Evans@xxxxxxxxxxxx>
- To: Tommi Airikka <airikka@xxxxxxxxx>
- Subject: Re: End of line instead of beginning of line
- Date: Fri, 16 Oct 2009 12:04:33 +0100
- Cc: zsh-users@xxxxxxxxxx
- In-reply-to: <c8c061b30910160337h6bcf2f3fubee9b51605f6ca82@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <c8c061b30910160337h6bcf2f3fubee9b51605f6ca82@xxxxxxxxxxxxxx>
On Fri, Oct 16, 2009 at 12:37:43PM +0200, Tommi Airikka wrote:
>
> In vi-mode, is there any way to get the cursor directly to the end of
> the line (insert mode) when pressing the up arrow for history, just by
> changing in my local .zshrc?
> It's really annoying that it defaults to the beginning of the line.
>
Do a search for up-line-or-history in zshzle(1); that will tell youy
why this state of woe exists.
I use something like
autoload -Uz up-line-or-beginning-search
autoload -Uz down-line-or-beginning-search
zle -N up-line-or-beginning-search up-line-or-beginning-search
zle -N down-line-or-beginning-search down-line-or-beginning-search
bindkey -v
bindkey "^[[A" up-line-or-beginning-search
bindkey "^[[B" down-line-or-beginning-search
Perfect? Probably not...
--
Dr. David Evans David.Evans@xxxxxxxxxxxx
Research Associate http://www.cl.cam.ac.uk/~de239
Computer Laboratory, University of Cambridge
Messages sorted by:
Reverse Date,
Date,
Thread,
Author