Linux: How to Install/Remove Packages
Here's how to install and remove Ubuntu Linux software packages.
The following are for Ubuntu Linux.
sudo apt-get install name
- Install a package.
sudo apt-get remove name
- Uninstall package.
sudo apt-get purge name
- Remove a package and its config files.
apt-cache search name
- Search for a package.
apt-cache show name
- Describe package.
apt-get showpkg name
- Show a package's dependencies.
List Installed Packages
- List all installed packages
Update All Installed Software
- Sync package index files from sources. (need to do this regularly)
- Upgrade all installed packages to latest versions (if any).
- Update OS kernel, and others.
# update all software (it'll ask to confirm) sudo apt-get update sudo apt-get upgrade sudo apt-get distupgrade
Launch Software Update GUI App
- Launch the package manager GUI App
Compile a software from source code
To install and compile a new software from source code , here's the typical steps:
gzip -d filename.tar.gz tar xvf filename.tar cd dirname ./configure make sudo make install # optional. This basically copy the binary to /usr/local/bin
Example: How to Build Emacs on Linux .