Ubuntu – What are all the apt command-line commands and options

aptcommand linedocumentation

I know they think that they are being helpful, but in fact they are being quite the opposite here in the apt --help and manpage:

Much like apt itself, its manpage is intended as an end user interface
and as such only mentions the most used commands and options partly to
not duplicate information in multiple places and partly to avoid
overwhelming readers with a cornucopia of options and details.

So basically in other words they only list a few of the commands and options and give you no idea about how to find out the rest which is greatly unhelpful if I am to use this tool.

So what are all the commands and options that they feel they are being 'helpful' not to provide, what are their details and usage, and how can I keep up-to-date with this information if they do not provide it officially? Or perhaps that has changed now and they are listed somewhere?

I am running Ubuntu GNOME 16.04 with GNOME 3.20.

Best Answer

  • Please improve this wiki and add your favourite apt commands :)


    apt changelog PACKAGE_NAME
    

    The above cmd. hows the changelog history for the specified package in reverse date order (newest first) in less format, pulled from changelogs.ubuntu.com


    apt full-upgrade
    

    (requires root privilege) a new name for apt-get dist-upgrade - see man apt-get:

    dist-upgrade in addition to performing the function of upgrade, also intelligently handles changing dependencies with new versions of packages; apt-get has a "smart" conflict resolution system, and it will attempt to upgrade the most important packages at the expense of less important ones if necessary. The dist-upgrade command may therefore remove some packages.


    apt search PACKAGE_NAME
    

    Almost the same as apt-cache search but with prettified output - line-spaced and coloured for easier reading:

    search performs a full text search on all available package lists for the POSIX regex pattern given. It searches the package names and the descriptions for an occurrence of the regular expression and prints out the package name and the short description, including virtual package names.


  • Related Question