Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Package information for non-installed programs in ZSH
On Tue, 5 Apr 2011 13:40:16 +0200
Oliver Keszöcze <keszocze@xxxxxxxxxxxxxxxxxx> wrote:
> Using BASH and Ubuntu I get messages such as
>
> The program 'gcc' can be found in the following packages:
> * gcc
> * pentium-builder
> Try: sudo apt-get install <selected package>
>
> if I try to run stuff I do not have currently installed.
It will be using a command-not-found handler. You can do this sort of
thing in recent versions of zsh if you find out what the back end is...
command_not_found_handler() {
print "Attempting to locate the command $1..."
# if you don't want to consider that the command has been handled...
return 1
}
% fumble
Attempting to locate the command fumble...
zsh: command not found: fumble
--
Peter Stephenson <pws@xxxxxxx> Software Engineer
Tel: +44 (0)1223 692070 Cambridge Silicon Radio Limited
Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, UK
Member of the CSR plc group of companies. CSR plc registered in England and Wales, registered number 4187346, registered office Churchill House, Cambridge Business Park, Cowley Road, Cambridge, CB4 0WZ, United Kingdom
Messages sorted by:
Reverse Date,
Date,
Thread,
Author