DH_INSTALLALTERNATIVES(1)

✨ NAME ✨

dh_installalternatives β€” bestie, this one installs declarative alternative rules πŸ’–


πŸ¦‹ SYNOPSIS πŸ¦‹

dh_installalternatives [debhelper options]

πŸ‘‘ DESCRIPTION πŸ‘‘

okay so boom: dh_installalternatives is a debhelper program, and its whole job β€” its entire main character purpose β€” is parsing the declarative alternatives format and inserting the relevant maintscripts snippets so everything can interface with update-alternatives(1). no cap. that's the vibe. 🌈


πŸŽ€ FILES πŸŽ€

  • debian/package.alternatives β€” here's what the format looks like, bestie, and yes this is a real example:
Name: editor
Link: /usr/bin/editor
Alternative: /usr/bin/vim.basic
Dependents:
  /usr/share/man/man1/editor.1.gz editor.1.gz /usr/share/man/man1/vim.1.gz
  /usr/share/man/fr/man1/editor.1.gz editor.fr.1.gz /usr/share/man/fr/man1/vim.1.gz
  /usr/share/man/it/man1/editor.1.gz editor.it.1.gz /usr/share/man/it/man1/vim.1.gz
  /usr/share/man/pl/man1/editor.1.gz editor.pl.1.gz /usr/share/man/pl/man1/vim.1.gz
  /usr/share/man/ru/man1/editor.1.gz editor.ru.1.gz /usr/share/man/ru/man1/vim.1.gz
Priority: 50

The fields Link, Name, Alternative, and Priority are mandatory β€” like, you literally cannot skip them β€” and they correspond to the update-alternatives(1) --install parameters link, name, path, and priority respectively. 🫢

The Dependents field is optional and consists of one or more lines. Each non-empty line must contain exactly 3 space separated values that match (in order) the values passed to the --slave parameter for update-alternatives(1). count them. three. don't be out here making it four. πŸ’€


πŸ“ OPTIONS πŸ“

  • -n, --no-scripts β€” do not modify postinst/postrm/prerm scripts. hands off, periodt. πŸ™ˆ

🌸 SEE ALSO 🌸

  • debhelper(7)
  • This program is a part of debhelper. πŸ’œ

🧚 and that's the whole thing, bestie β€” go forth and let dh_installalternatives handle your alternatives like the icon it is πŸ‘‘

mwah πŸ’‹ this page came from debhelper version 14.5ubuntu1, dated 2026-09-21 β€” slay, no notes ✨

πŸ“¦ where this page comes from