]> git.saurik.com Git - apt.git/blame - doc/apt.8.xml
Merge branch 'fix-https-noproxy' of github.com:patcable/apt
[apt.git] / doc / apt.8.xml
CommitLineData
81d18368
MV
1<?xml version="1.0" encoding="utf-8" standalone="no"?>
2<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
5abbf5bb
DK
4<!ENTITY % aptent SYSTEM "apt.ent"> %aptent;
5<!ENTITY % aptverbatiment SYSTEM "apt-verbatim.ent"> %aptverbatiment;
6<!ENTITY % aptvendor SYSTEM "apt-vendor.ent"> %aptvendor;
81d18368
MV
7]>
8
9<refentry>
10
11 <refentryinfo>
81d18368
MV
12 &apt-author.team;
13 &apt-email;
14 &apt-product;
15 <!-- The last update date -->
ab5b1d0d 16 <date>2015-10-20T00:00:00Z</date>
81d18368
MV
17 </refentryinfo>
18
19 <refmeta>
20 <refentrytitle>apt</refentrytitle>
21 <manvolnum>8</manvolnum>
22 <refmiscinfo class="manual">APT</refmiscinfo>
23 </refmeta>
24
25 <!-- Man page title -->
26 <refnamediv>
27 <refname>apt</refname>
54864645 28 <refpurpose>command-line interface</refpurpose>
81d18368
MV
29 </refnamediv>
30
31 &synopsis-command-apt;
32
33 <refsect1><title>Description</title>
9fd6772b
DK
34 <para><command>apt</command> provides a high-level commandline interface for
35 the package management system. It is intended as an end user interface and
36 enables some options better suited for interactive usage by default
37 compared to more specialized APT tools like &apt-get; and &apt-cache;.
38 </para><para>
39 Much like <command>apt</command> itself, its manpage is intended as an end
40 user interface and as such only mentions the most used commands and options
41 partly to not duplicate information in multiple places and partly to avoid
89497574 42 overwhelming readers with a cornucopia of options and details.
81d18368
MV
43 </para>
44
45 <variablelist>
9fd6772b
DK
46 <varlistentry><term><option>update</option> (&apt-get;)</term>
47 <listitem><para><option>update</option> is used to download package
48 information from all configured sources. Other commands operate on
49 this data to e.g. perform package upgrades or search in and display
50 details about all packages available for installation.
132a7f88
MV
51 </para></listitem>
52 </varlistentry>
53
9fd6772b
DK
54 <varlistentry><term><option>upgrade</option> (&apt-get;)</term>
55 <listitem><para><option>upgrade</option> is used to install available
56 upgrades of all packages currently installed on the system from the
57 sources configured via &sources-list;. New packages will be
58 installed if required to statisfy dependencies, but existing
59 packages will never be removed. If an upgrade for a package requires
60 the remove of an installed package the upgrade for this package
61 isn't performed.
81d18368
MV
62 </para></listitem>
63 </varlistentry>
64
9fd6772b
DK
65 <varlistentry><term><option>full-upgrade</option> (&apt-get;)</term>
66 <listitem><para><literal>full-upgrade</literal> performs the function of
67 upgrade but will remove currently installed packages if this is
68 needed to upgrade the system as a whole.
69 </para></listitem>
81d18368
MV
70 </varlistentry>
71
9fd6772b
DK
72 <varlistentry><term><option>install</option>, <option>remove</option>, <option>purge</option> (&apt-get;)</term>
73 <listitem><para>Performs the requested action on one or more packages
74 specified via &regex;, &glob; or exact match. The requested action
d072150a 75 can be overridden for specific packages by append a plus (+) to the
9fd6772b
DK
76 package name to install this package or a minus (-) to remove it.
77 </para><para>
78 A specific version of a package can be selected for installation by
79 following the package name with an equals (=) and the version of the
80 package to select. Alternatively the version from a specific release can be
81 selected by following the package name with a forward slash (/) and
9feb98eb 82 codename (&debian-stable-codename;, &debian-testing-codename;, sid …) or suite name (stable,
9fd6772b
DK
83 testing, unstable). This will also select versions from this release
84 for dependencies of this package if needed to satisfy the request.
85 </para><para>
86 Removing a package removes all packaged data, but leaves usually
87 small (modified) user configuration files behind, in case the
d072150a
JR
88 remove was an accident. Just issuing an installation request for the
89 accidentally removed package will restore its function as before in
90 that case. On the other hand you can get rid of these leftovers
91 by calling <command>purge</command> even on already removed
92 packages. Note that this does not affect any data or configuration
9fd6772b
DK
93 stored in your home directory.
94 </para></listitem>
81d18368
MV
95 </varlistentry>
96
9fd6772b
DK
97 <varlistentry><term><option>autoremove</option> (&apt-get;)</term>
98 <listitem><para>
99 <literal>autoremove</literal> is used to remove packages that were
100 automatically installed to satisfy dependencies for other packages
101 and are now no longer needed as dependencies changed or the package(s)
102 needing them were removed in the meantime.
103 </para><para>
d072150a
JR
104 You should check that the list does not include applications you have
105 grown to like even though they were once installed just as a
9fd6772b
DK
106 dependency of another package. You can mark such a package as manually
107 installed by using &apt-mark;. Packages which you have installed explicitly
d072150a 108 via <command>install</command> are also never proposed for automatic removal.
9fd6772b 109 </para></listitem>
825220b5
JAK
110 </varlistentry>
111
9fd6772b
DK
112 <varlistentry><term><option>search</option> (&apt-cache;)</term>
113 <listitem><para><option>search</option> can be used to search for the given
d072150a 114 &regex; term(s) in the list of available packages and display
9fd6772b
DK
115 matches. This can e.g. be useful if you are looking for packages
116 having a specific feature. If you are looking for a package
117 including a specific file try &apt-file;.
259d88d9
MV
118 </para></listitem>
119 </varlistentry>
120
9fd6772b
DK
121 <varlistentry><term><option>show</option> (&apt-cache;)</term>
122 <listitem><para>Show information about the given package(s) including
123 its dependencies, installation and download size, sources the
124 package is available from, the description of the packages content
d072150a 125 and much more. It can e.g. be helpful to look at this information
9fd6772b
DK
126 before allowing &apt; to remove a package or while searching for
127 new packages to install.
259d88d9
MV
128 </para></listitem>
129 </varlistentry>
9fd6772b
DK
130
131 <varlistentry><term><option>list</option> (work-in-progress)</term>
132 <listitem><para><option>list</option> is somewhat similar to <command>dpkg-query --list</command>
133 in that it can display a list of packages satisfying certain
134 criteria. It supports &glob; patterns for matching package names as
135 well as options to list installed (<option>--installed</option>),
136 upgradeable (<option>--upgradeable</option>) or all available
137 (<option>--all-versions</option>) versions.
259d88d9
MV
138 </para></listitem>
139 </varlistentry>
140
9fd6772b
DK
141 <varlistentry><term><option>edit-sources</option> (work-in-progress)</term>
142 <listitem><para><literal>edit-sources</literal> lets you edit
143 your &sources-list; files in your preferred texteditor while also
144 providing basic sanity checks.
c4383ac4
MV
145 </para></listitem>
146 </varlistentry>
147
259d88d9 148
81d18368
MV
149 </variablelist>
150 </refsect1>
81d18368 151
d072150a 152 <refsect1><title>Script Usage and Differences from Other APT Tools</title>
a555cf8b 153 <para>
d072150a
JR
154 The &apt; commandline is designed as an end-user tool and it may
155 change behavior between versions. While it tries not to break
156 backward compatibility this is not guaranteed either if a change
157 seems beneficial for interactive use.
9fd6772b
DK
158 </para><para>
159 All features of &apt; are available in dedicated APT tools like &apt-get;
160 and &apt-cache; as well. &apt; just changes the default value of some
d072150a
JR
161 options (see &apt-conf; and specifically the Binary scope). So you should
162 prefer using these commands (potentially with some additional options
163 enabled) in your scripts as they keep backward compatibility as much as possible.
9fd6772b 164 </para>
81d18368
MV
165 </refsect1>
166
167 <refsect1><title>See Also</title>
9a591666 168 <para>&apt-get;, &apt-cache;, &sources-list;,
9fd6772b 169 &apt-conf;, &apt-config;,
81d18368
MV
170 The APT User's guide in &guidesdir;, &apt-preferences;, the APT Howto.</para>
171 </refsect1>
172
173 <refsect1><title>Diagnostics</title>
174 <para><command>apt</command> returns zero on normal operation, decimal 100 on error.</para>
175 </refsect1>
176 &manbugs;
177</refentry>