Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: How to enable history completion in command line?
- X-seq: zsh-users 17521
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-user <zsh-users@xxxxxxx>
- Subject: Re: How to enable history completion in command line?
- Date: Tue, 01 Jan 2013 16:08:01 -0800
- In-reply-to: <20130101224452.GD2054@localhost.localdomain>
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <20130101224452.GD2054@localhost.localdomain>
On Jan 2, 6:44am, Han Pingtian wrote:
}
} How can I enable history completion in the command line? That's typing
} a command then hit some key to let zsh completes the whole command
} line based on history.
Are you sure you're not looking for history-beginning-search-backward?
Completion is extremely word-oriented, so using it to retrieve anything
that has whitespace and other syntactic separators is difficult. There
are tricks you can do with "compadd -Q -U" to cause multi-word strings
to be inserted onto the command line, but attempting to do any sort of
menu completion (with limited exceptions for menu selection) will fail
because completion will begin to limit itself to the single word nearest
the cursor as soon as the first replacement is done.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author