Multiplatform jq installer action
  • Shell 67.3%
  • PowerShell 32.7%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Daniel Carbone 4fcb5062d7
feat: add jq 1.8.1 and 1.8.2, default to 1.8.2 (#27)
- Add 1.8.1 and 1.8.2 to the test-linux and test-container matrices.
- Bump default version in action.yaml from 1.7.1 to 1.8.2.
- Update README tested-version list and default snippet.
- Update example workflow dispatch defaults to 1.8.2.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-06-24 13:57:18 -05:00
.github feat: add jq 1.8.1 and 1.8.2, default to 1.8.2 (#27) 2026-06-24 13:57:18 -05:00
scripts fix(security): verify download integrity and harden install scripts (#25) 2026-06-24 13:26:34 -05:00
tests/unit docs+tests: prepare v4 release 2026-06-24 13:39:00 -05:00
.gitignore initial commit 2022-10-18 11:34:54 -05:00
action.yaml feat: add jq 1.8.1 and 1.8.2, default to 1.8.2 (#27) 2026-06-24 13:57:18 -05:00
LICENSE Initial commit 2022-10-18 08:02:56 -05:00
README.md feat: add jq 1.8.1 and 1.8.2, default to 1.8.2 (#27) 2026-06-24 13:57:18 -05:00

install-jq-action

Multiplatform jq installer action

Tests - Install jq Action

This action is tested against the following versions of jq:

Modern releases (jqlang/jq — 1.7+)

Legacy releases (stedolan/jq — 1.5 and 1.6)

Index

  1. Examples
  2. Action Source
  3. Action Inputs
  4. Action Outputs
  5. Security

Examples

Action Inputs

version

  version:
    required: false
    description: "Version of jq to install"
    default: "1.8.2"

Must be a dot-separated numeric version string (e.g. 1.7.1, 1.8.0).

  • 1.7 and newer are downloaded from the jqlang/jq repository and support a wider set of architectures: amd64, arm64, armhf, armel, and i386.
  • 1.5 and 1.6 are downloaded from the legacy stedolan/jq repository and support linux32, linux64, and osx-amd64.

force

  force:
    required: false
    description: "If 'true', does not check for existing jq installation before continuing."
    default: 'false'

GitHub's own hosted runners come with a version of jq pre-installed.

Setting this to true will install the version you specify into the tool cache, superseding the preinstalled version. Setting this to true can also help ensure the same version is used across both self-hosted and remote runners.

Action Outputs

found

  found:
    description: "If 'true', jq was already found on this runner"

installed

  installed:
    description: "If 'true', jq was installed by this action"

Security

Starting with v4 this action performs integrity verification on every download:

  • jq 1.7 and newer: the binary's SHA-256 digest is checked against the release's sha256sum.txt before it is installed. The install fails if the digest does not match. If no sha256sum.txt is published for a release (e.g. the original jq 1.7.0 tag) a warning is printed and installation continues.
  • jq 1.5 / 1.6 (legacy): no checksum file is published by the upstream stedolan/jq project, so no verification is performed.

curl is hardened with --fail so that HTTP error responses (4xx/5xx) abort the download rather than writing the error page to disk as the binary.

All four install scripts validate the version input against the pattern ^[0-9]+\.[0-9]+(\.[0-9]+)*$ and reject malformed values (including path-traversal attempts) before constructing any download URL.