Usage: firefox-prefetch-addons [FLAGS...] [ADDONS...]
A simple bash script to fetch Firefox addons IDs, to be used in ExtensionSettings policy.

ADDONS can be both just the name of the extension or the URL of the extensions page, so
for example: "ublock-origin" and "https://addons.mozilla.org/en-US/firefox/addon/ublock-origin/"
are treated as the same.

Options:

  --format-json: format resulting addons object as JSON.
  --format-nix: format resulting addons object as a Nix expression (requires the "nix" command to be installed).
  --pretty: prettify resulting object output (requires "alejandra" to be installed for Nix output).
  --no-pretty: do not prettify resulting object output.

Dependencies:

  alejandra: OPTIONAL, used for formatting the output Nix expression.
  jq: REQUIRED, used to properly work with extensions JSON values.
  nix: OPTIONAL, used to transform the JSON output to a Nix expression.
  unzip: REQUIRED, used to unzip downloaded extension.
  wget: REQUIRED, used to download manifest of extensions.

2025 (c) Gustavo "Guz" L. de Mello <contact@guz.one>
Licensed under WTFPL license. PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND.
Description
A simple bash script to fetch Firefox addons IDs, to be used in ExtensionSettings policy.
Readme WTFPL 39 KiB
Languages
Shell 70.6%
Nix 29.4%