Mailinglist Archive: opensuse-factory (464 mails)

< Previous Next >
[opensuse-factory] bash extension: "command-not-found"
  • From: Pavol Rusnak <prusnak@xxxxxxx>
  • Date: Tue, 26 Feb 2008 16:33:23 +0100
  • Message-id: <47C43143.5060509@xxxxxxx>
Hello all!

During Hackweek I implemented project command-not-found for
openSUSE [1]. You can look at the picture [2] to get the idea.
In first example, user types "epihpany" instead of "epiphany" and
handler suggests correct spelling. After this, user tries running
epiphany, but it is not installed, so handler shows list of packages
that provide this program. In the third example, user runs program that
is not found, but package providing it is installed (meaning that
program is not in user's path - probably intended to be run only by root).
So my question is: do you want this functionality in openSUSE 11.0?
If you would like to test this feature, packages are ready in
BuildService [3] or you can download them directly from repository [4].
You have to also add these 3 lines to your /etc/bash.bashrc.local file
(or ~/.bashrc):

if [ -f /etc/bash_command_not_found ]; then
. /etc/bash_command_not_found
fi

If you have any ideas or in case you have found a bug, I would be glad
to hear from you. Thanks in advance!

Links:
[1]http://idea.opensuse.org/content/ideas/command-not-found-for-opensuse
[2]http://stick.gk2.sk/projects/command-not-found/cnf.png
[3]https://build.opensuse.org/project/show?project=home:prusnak:command-not-found
[4]http://download.opensuse.org/repositories/home:/prusnak:/command-not-found/

PS: The handler could be attached to any other shell which provides
handling events when command is not found, not only bash (currently zsh).

--
Best Regards / S pozdravom,

Pavol RUSNAK SUSE LINUX, s.r.o
Package Maintainer Lihovarska 1060/12
PGP 0xA6917144 19000 Praha 9, CR
prusnak[at]suse.cz http://www.suse.cz
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-factory+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-factory+help@xxxxxxxxxxxx

< Previous Next >