actionlint-pants-plugin
A Pantsbuild plugin that lints GitHub Actions workflow files with
actionlint: workflow syntax, ${{ }} expressions, action inputs,
runner labels, and the shell scripts in run: steps.
Installation
Add the plugin to pants.toml. Pants ignores dot-directories by default, so .github/ MUST be made visible too:
[GLOBAL]
plugins = ["actionlint-pants-plugin==<version>"]
pants_ignore.add = ["!.github/"]
Declare the workflow targets next to the workflow files:
# .github/workflows/BUILD
github_workflow_sources()
Then run actionlint through the lint goal:
pants lint .github/workflows:: # or `pants lint ::`
How it works
actionlint is downloaded as a static binary; nothing is installed into a Pants resolve. The plugin registers
a github_workflow_sources target generator, which yields one github_workflow_source target per *.yml or
*.yaml file next to the BUILD file, and a pants lint integration over those targets. For each run Pants:
- Puts the workflow files, their
dependenciesand the config file (see below) into a sandbox, together with an empty.gitdirectory:actionlintonly reads its config and validates localuses: ./...references inside a git repository, and a sandbox is not one. - Downloads
shellcheckthrough Pants'[shellcheck]subsystem and passes it as-shellcheck, sorun:steps are checked as they would be withshellcheckon thePATH. Set[actionlint].shellcheck = falseto opt out. Thepyflakesintegration is always disabled, as Pants ships nopyflakestool. - Runs
actionlint -coloronce per batch on the workflow files. The linter fails whenactionlintdoes.
Target fields
| Field | Target | Purpose |
|---|---|---|
sources |
github_workflow_sources |
Globs of workflow files, relative to the BUILD file. Default: ["*.yaml", "*.yml"]. |
source |
github_workflow_source |
One workflow file. |
dependencies |
both | Targets the workflow uses: the files target holding a local action's action.yml, a reusable workflow, a script a step runs. actionlint validates the inputs of a local action whose action.yml is present, and pants --changed-since re-lints the workflow when a dependency changes. |
skip_actionlint |
both | If true, the file is excluded from pants lint. |
overrides |
github_workflow_sources |
Per-file values for the fields above, e.g. overrides={"release.yml": {"skip_actionlint": True}}. |
Configuration
actionlint reads .github/actionlint.yaml or .github/actionlint.yml from the repository root
(reference). Pants includes that file
automatically. Point [actionlint].config at a config file elsewhere to pass it as -config-file, which
takes precedence over the repository config.
| Option | Default | Purpose |
|---|---|---|
[actionlint].skip |
false |
Skip actionlint during pants lint. |
[actionlint].args |
[] |
Extra arguments for actionlint, e.g. -ignore 'SC2086:.+' or -oneline. They follow the plugin's own flags, so a repeated flag overrides it. |
[actionlint].config |
unset | Path to an actionlint config file, passed as -config-file. Disables discovery. |
[actionlint].config_discovery |
true |
Include .github/actionlint.yaml or .github/actionlint.yml from the build root. |
[actionlint].shellcheck |
true |
Run shellcheck on run: steps. The binary is the [shellcheck].version release; the other [shellcheck] options do not apply. |
[actionlint].version |
bundled default | actionlint release to download. |
[actionlint].known_versions |
bundled default | Checksums of downloadable releases; extend to use another version. |
Using a different actionlint version
Add the release's checksums and sizes to known_versions and set version:
[actionlint]
version = "1.7.13"
known_versions.add = [
"1.7.13|linux_arm64 |<sha256>|<size>",
"1.7.13|linux_x86_64|<sha256>|<size>",
"1.7.13|macos_arm64 |<sha256>|<size>",
"1.7.13|macos_x86_64|<sha256>|<size>",
]
Compute each line with curl -L $URL | tee >(wc -c) >(shasum -a 256) >/dev/null, where $URL is the
actionlint_<version>_<os>_<arch>.tar.gz asset of the
GitHub release (linux/darwin, amd64/arm64).
Supported versions
| Plugin | Pants | Python | actionlint |
|---|---|---|---|
0.x |
2.33 |
3.14 |
>=1.7,<2 |
Pants loads plugins into its own interpreter, so the plugin requires the Python version Pants runs on.
Releases
Wheels are published to PyPI. Release notes live in the changelog and on the GitHub releases page.
Contributing, Bug Reports and Feature Requests
This plugin lives in the pants-plugin-depot repo. See its CONTRIBUTING.md, or open an issue.
Metadata
Release files for actionlint-pants-plugin 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| actionlint_pants_plugin-0.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Release files / actionlint_pants_plugin-0.1.3-py3-none-any.whl
| Download URL | actionlint_pants_plugin-0.1.3-py3-none-any.whl |
|---|---|
| Size | 15.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8c62ecf638412764f0957494af6ecb6bac713e6896390b21523b9586b88ed5a1
|
|
BLAKE2b-256 checksum How to use checksums |
82d411ec51e60889414195a2ff22464a6df1a65e7fcc74b142bbffeda9408c84
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 17, 2026.
Transparency logSecurity for actionlint-pants-plugin 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 1 file in this release has been uploaded with provenance metadata.
Attestation for actionlint_pants_plugin-0.1.3-py3-none-any.whl
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Oct 17, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.