{eks}catid=87|keyword=terminal|teaser|alpha{/eks}

 

Ubuntu documentation

apt-get Installation commands

  • apt-get install <package_name>

    This command installs a new package.

  • apt-get build-dep <package_name>

    This command searches the repositories and installs the build dependencies for <package_name>. If the package is not in the repositories it will return an error.

  • aptitude install <package_name>

    Aptitude is an Ncurses viewer of packages installed or available. Aptitude can be used from the command line in a similar way to apt-get. See man aptitude for more information.

  • APT and aptitude will accept multiple package names as a space delimited list. For example:
    apt-get install <package1_name> <package2_name> <package3_name>

    Use the -s flag to simulate an action."sudo apt-get -s install <package_name>" will simulate installing

    the package showing you what packages will be installed and configured. 

 

auto-apt

  • auto-apt run <command_string>

    When invoked, the auto-apt command automatically installs packages upon missing file access. If a program tries to access a file known to belong in an uninstalled package, auto-apt will install that package using apt-get. This feature requires apt and sudo to work.

  • Auto-apt keeps databases which need to be kept up-to-date in order for it to be effective. This is achieved by calling the commands auto-apt update, auto-apt updatedb and auto-apt update-local.
  • Usage example
    • IconsPage/example.png You're compiling a program and, all of a sudden, there's an error because it needs a file you don't have. The program auto-apt asks you to install packages if they're needed, stopping the relevant process and continuing once the package is installed.

      # auto-apt run ./configure
      It will then ask to install the needed packages and call apt-get automatically. If you're running X, a graphical interface will replace the default text interface.