PDA

View Full Version : [ubuntu] apt-get package suggestion when typing in cmd line



mohammadthalif
May 15th, 2009, 05:52 AM
Hi all,

When I type a wrong command the apt-get match's a the package and suggest for installation. how this is done. can any one explain me.

for example.

$pi
The program 'pi' is currently not installed. You can install it by typing:
sudo apt-get install pi

Thanks ):P

lindsay7
May 15th, 2009, 06:50 AM
I am not sure what you are asking, it you want to install a program using the terminal you type


sudo apt-get install pi if pi is the program name

the terminal will ask for your password, type that in, you will not see what you type, just hit enter.

mohammadthalif
May 15th, 2009, 07:13 AM
hi lindsay7

I know to install in the command line using apt get.

My qurrey is that. when I type a command in the command line pi it automaticaly matches the package and return the suggestion like

The program 'pi' is currently not installed. You can install it by typing:
sudo apt-get install pi


how this is achived. Do I need to configure apt get to report like that. If you see in debian apt-get is there but when i enter pi or any command it is not suggestion like done in the ubuntu. I want to configure debian too like ubuntu does

Thanks

lncoll
May 15th, 2009, 07:43 AM
This feature is done by the command-not-found package, this is all that I know about.
You can look in Synaptic what files does this package install, there is a README file and some doc.

mohammadthalif
May 15th, 2009, 09:59 AM
Thanks lncoll

This is what I was looking for.