APT-MARK(8)

๐ŸŽ€ APT-MARK(8) ๐ŸŽ€

okay bestie, welcome to the APT-MARK(8) manual page โ€” yes, the whole apt-mark situation โ€” and it's literally your front-row seat to showing, setting, and unsetting various settings for a package. no cap, it's useful. ๐Ÿ’…


โœจ NAME โœจ

apt-mark โ€” show, set and unset various settings for a package.


๐Ÿฆ‹ SYNOPSIS ๐Ÿฆ‹

       apt-mark {-f=filename | {auto | manual} pkg...  |
                {showauto | showmanual} [pkg...] } | {-v | --version} |
                {-h | --help}

       apt-mark {hold | unhold | install | remove | purge} pkg...  |
                {showhold | showinstall | showremove | showpurge} [pkg...]

๐ŸŒธ DESCRIPTION ๐ŸŒธ

apt-mark is like the unified front-end for setting various settings for a package. it can mark a package as being automatically or manually installed, or change dpkg selections such as hold, install, deinstall and purge โ€” and those selections are respected by things like apt-get dselect-upgrade or aptitude, iykyk. ๐Ÿซถ


๐Ÿ’– AUTOMATICALLY AND MANUALLY INSTALLED PACKAGES ๐Ÿ’–

okay so here's the vibe: when you request that a package is installed, and as a result other packages get installed to satisfy its dependencies, those dependencies are marked as being automatically installed, while the package you installed explicitly is marked as manually installed. once an automatically installed package is no longer depended on by any manually installed package, it's considered no longer needed and apt-get or aptitude will at least suggest removing them. slay, but also bye. ๐Ÿ‘‹

  • auto โ€” marks a package as being automatically installed, which will cause the package to be removed when no more manually installed packages depend on this package.
  • manual โ€” marks a package as being manually installed, which will prevent the package from being automatically removed if no other packages depend on it.
  • minimize-manual โ€” marks (transitive) dependencies of metapackages as automatically installed. this can be used after an installation, for example, to minimize the number of manually installed packages; or continuously on systems managed by system configuration metapackages. iconic behavior honestly. โœจ
  • showauto โ€” prints a list of automatically installed packages, with each package on a new line. all automatically installed packages will be listed if no package is given. if packages are given, only those which are automatically installed will be shown.
  • showmanual โ€” works in the same way as showauto, except it prints a list of manually installed packages instead. twin behavior. ๐Ÿ’–

๐ŸŒŸ Options ๐ŸŒŸ

  • -f=filename, --file=filename โ€” Read/Write package stats from the filename given with the parameter filename instead of from the default location, which is extended_states in the directory defined by the Configuration Item: Dir::State.

๐Ÿ”’ PREVENT CHANGES FOR A PACKAGE ๐Ÿ”’

  • hold โ€” marks a package as held back, which will prevent the package from being automatically installed, upgraded or removed. it's giving "not today." โœ‹
  • unhold โ€” cancels a previously set hold on a package so all actions are allowed again.
  • showhold โ€” prints a list of packages on hold in the same way as for the other show commands.

๐Ÿ“… SCHEDULE PACKAGES FOR INSTALL, REMOVE AND PURGE ๐Ÿ“…

some front-ends like apt-get dselect-upgrade can be used to apply previously scheduled changes to the install state of packages. such changes can be scheduled with the install, remove (also known as deinstall) and purge commands. packages with a specific selection can be displayed with showinstall, showremove and showpurge respectively. more information about these so called dpkg selections can be found in dpkg(1). ๐Ÿซก


โœจ OPTIONS โœจ

  • -h, --help โ€” Show a short usage summary.
  • -v, --version โ€” Show the program version.
  • --audit โ€” Show audit (and notice) messages. This overrides the quiet option, but only for notice messages, not progress ones.
  • -c, --config-file โ€” Configuration File; Specify a configuration file to use. The program will read the default configuration file and then this configuration file. If configuration settings need to be set before the default configuration files are parsed, specify a file with the APT_CONFIG environment variable. See apt.conf(5) for syntax information.
  • -o, --option โ€” Set a Configuration Option; this will set an arbitrary configuration option. The syntax is -o Foo::Bar=bar. -o and --option can be used multiple times to set different options.
  • --cli-version โ€” Requests a specific CLI version. This is a pattern that takes a MAJOR.MINOR version. You may omit the MINOR version, in which case the latest supported minor level will be used.

Version tracks are presented as follows: the version 3.2 has equivalent versions 0.32, 1.22, and 2.12, implementing new features for their specified major versions.

A special case is the X.9 version pattern: a version like 2.9 is followed by 3.0, but 2.10 follows directly on 2.8; given that we use odd version numbers as development series (2.9 is the 3.0 development series).

This feature has been introduced in APT 3.1.10, and replaces the binary-specific configuration. You may use the APT::Version to similar effect on older binaries, for example, use -o APT::Version=2 to make apt(8) behave like the 2.x series.

The default value is the current APT version for apt(8) and 0.(10 * major + minor) for the classic commands. The 0.X series is soft-deprecated and the other commands will roll over to the 2.x series in the future.

  • --no-color, --color โ€” Turn colors on or off. Colors are on by default on supported terminals for apt(8) and can also be disabled using the NO_COLOR or APT_NO_COLOR environment variables, or further configured by the APT::Color configuration option and scope, see apt.conf(5) for information on that.

๐Ÿ“ FILES ๐Ÿ“

  • /var/lib/apt/extended_states โ€” Status list of auto-installed packages. Configuration Item: Dir::State::extended_states.

๐ŸŒˆ SEE ALSO ๐ŸŒˆ

apt-get(8), aptitude(8), apt.conf(5)


๐Ÿ’€ DIAGNOSTICS ๐Ÿ’€

apt-mark returns zero on normal operation, non-zero on error. simple as that bestie.


๐Ÿ™ˆ BUGS ๐Ÿ™ˆ

APT bug page[1]. If you wish to report a bug in APT, please see /usr/share/doc/debian/bug-reporting.txt or the reportbug(1) command.


๐Ÿ‘‘ AUTHORS ๐Ÿ‘‘

Mike O'Connor

APT team


๐Ÿงš NOTES ๐Ÿงš

  1. APT bug page https://bugs.debian.org/src:apt

๐Ÿ’– brought to you by APT 3.3.5, dated 14 September 2024 โ€” mwah ๐Ÿ’‹

๐Ÿ“ฆ where this page comes from