After doing a man apt-get
and cursory Google search it's not clear how I find new programs to install (from the internet) using apt-get
(which is amazingly powerful and simple coming from another Linux distro).
I'm using Ubuntu Server 8.04 LTS (an inherited system used for some random work), so no GUI.
Anyone have quick advice here?
I always use packages.ubuntu.com
Also you can use
apt-cache search
for command-line searching. Or you can use the GUI package manager (Ubuntu Software Center / Synaptic) for searching software.If you search for "nvidia settings".
The output is:
You see 2 packages
nvidia-settings
andnvidia-settings-updates
.To find the related binary to the package
nvidia-settings
.The output is:
nvidia-settings
is the binary name to start the program.With binaries in particular there is an application that is automatically run if you run a command that is not installed. For example,
Other than that, there are searches:
apt-cache search <query>
oraptitude search <query>
which can be preferable if you want to get really involved with filters.You can try the program 'aptitude' from the command line. It is a graphical package manager. Remember to append sudo to the program to do any real installations. 'sudo aptitude'. You can also use aptitude just like apt-get; "sudo aptitude install". I prefer apt-get for single packages that I know the names for.
Also, are you just on a command line? If you have a desktop you can use System -> Preferences -Synaptic, or the Ubuntu Software Center. They function nearly the same however they have a simpler package search.
I think, you are referring to the binary program name included in the package. I use this technique to find this:
simply type
dpkg -L <package-name>
in a terminal, it will display all files installed by that package, then you can recognize the binary program names by looking at their location. Usually programs are installed in/usr/bin
directory or/sbin
directory.Let's see an example:
Note that, the program name of gnome-screenshot package is
gnome-screenshot
.You asked
Sometimes the terminal can tell your the package name required to be installed to have a desired program. It happens when the program is in Standard repository and you have enabled those repository.
For example, If I type
gnome-documents
when no such package is installed, the terminal will tell be this:But, in this case, I should at least know the program name
You can get a (long) list of installable packages by typing
apt-get install
and then hitting TAB twice (for autocomplete). This is limited because it doesn't tell you what the packages do (Synaptic or Software Centre would be better for this) but it can be useful when you can't remember the exact name of a package. You can also type the first part of the package name (egopenoffice
) to get a shorter list of more relevant packages.you can run (preferably in your ~/.bashrc)
when you type:
it will propose install then start typing part of the name - for example nvidia
and you will see the available choices starting with nvidia
Use command-line tool if you know the package name you want. I you don't, use software center. You can get the package name via software center and use it in the terminal, if you really need to use apt-get tool from command line. And usually package name is the same as program name.