Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Simple Tip of the Day
- X-seq: zsh-users 9592
- From: Konstantin Sobolev <kos@xxxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: Simple Tip of the Day
- Date: Sat, 29 Oct 2005 16:37:58 +0400
- In-reply-to: <87ek65zwuw.fsf@xxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- Organization: SupportWizard
- References: <ci14m1hm45ig6umsu2v0tkini1gp0bad3r@xxxxxxx> <87ek65zwuw.fsf@xxxxxxxxxxxxxxxx>
- Reply-to: kos@xxxxxxxxxxxxxxxxx
On Friday 28 October 2005 15:47, Hannu Koivisto wrote:
> bindkey -s '^[[5~' 'cds\r' # "PageUp"
>
> Just in case you are wondering what that 'cds' is, it is an
> interactive way to select a directory from the directory
> stack-treated-as-history, along the lines of a similar feature in
> 4nt:
>
> cds () {
> local DIR="$PWD"
> if [[ ! -z "$dirstack" ]]; then
> DIR=$(print -rl $dirstack | tac \
>
> | iselect -a -f -n chdir -Q "$PWD" -t "Change directory to..."
> | -p ${#dirstack})
>
> fi
> cd "$DIR"
> }
I'm using menu completion for this:
bindkey "^Z" "menu-complete"
bindkey -s '\ec' 'cd -^Z'
--
/KoS
* Any program will expand to fill all memory PLUS ONE BYTE!
Messages sorted by:
Reverse Date,
Date,
Thread,
Author