3

When running the command quickly I get this output:

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

However when running:

apt-cache policy quickly

I just get:

N: Unable to locate package quickly

So therefore as the package quickly isn't in the repositories, where is the thing which tells me how to install a not currently installed program when I type a command that would belong to it getting its list of applications from? How does it get its list of programs and where from? Even if this is just an error, it reveals some of the workings of this program as it shows that it's not just looking at the package list which is downloaded with sudo apt-get update, otherwise it would know that the program does not exist. Also, is this just built-in functionality in gnome-terminal or is the thing responsible for the helpful message a separate application which can be uninstalled?

2

At the end of /etc/bash.bashrc you'll find some commands which ultimately define the bash function command_not_found_handle. Then man bash tells us that this command is invoked when a non-existing command is typed in. On my machine, the handle invokes /usr/lib/command-not-found as a python script. This again leads into /usr/lib/python3/dist-packages/CommandNotFound/CommandNotFound.py which seems to invoke apt-get or aptitute (search for the two in the file).

  • So why is there this error with quickly? Just the datebase not updated properly or something? – user364819 Dec 24 '15 at 19:28
  • Hmm, I am on a Linux Mint currently and when I run apt-cache policy quickly I get a nice output for quickly. So I guess it is some db mismatch. There is some talk about db and BinaryDatabase in the python program, but I am not into it enough to immediately see whether and when this is updated. – Harald Dec 24 '15 at 19:36
  • Well, are the Linux Mint repositories the same as the Ubuntu ones? – user364819 Dec 24 '15 at 19:43
  • Well, if it just stays like this for ever I'll file a bug report... – user364819 Dec 24 '15 at 19:44
  • No, Mint has its own repos, but it is based on Ubuntu. But I now logged into a machine with Ubuntu 14.04 and the policy command returns an installation candidate 12.08.1 there just fine. – Harald Dec 24 '15 at 19:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy