aptitude cheatsheet

aptitude is a great alternative to apt-get and the best way to install, remove, upgrade, and otherwise administer packages on you system with apt. aptitude solves orphaned dependencies and has a curses interface that blows the doors off of dselect. Finally, and most importantly, it takes advantage of one tool, doing many many operations:

<th>
  Description
</th>
<td>
  Running it with no arguments brings up a curses based interface to search, navigate, install, update and otherwise administer packages
</td>
<td>
  Installing software for your system, installing needed dependencies as well
</td>
<td>
  Download packages to the package cache as necessary, but do not install or remove anything.
</td>
<td>
  Removing packages as well as orphaned dependencies
</td>
<td>
  Removing packages and orphaned dependencies as well as any configuration files left behind
</td>
<td>
  Search for packages in the local apt package lists
</td>
<td>
  Update the local packages lists
</td>
<td>
  Upgrade any installed packages that have been updated
</td>
<td>
  Delete any downloaded files necessary for installing the software on your system
</td>
<td>
  Upgrade packages, even if it means uninstalling certain packages
</td>
<td>
  Show details about a package name
</td>
<td>
  Delete only out-of-date packages, but keep current ones
</td>
<td>
  Fix a package at it&#8217;s current version, and don&#8217;t update it
</td>
Syntax
aptitude
aptitude install
aptitude -d install
aptitude remove
aptitude purge
aptitude search
aptitude update
aptitude upgrade
aptitude clean
aptitude dist-upgrade
aptitude show
aptitude autoclean
aptitude hold

aptitude uses many of the same commands as apt-get. It is not a good idea to use both, you should either use aptitude or apt-get exclusively, or your dependencies might get confused.