# ci: Lint GitHub Actions workflows with actionlint \(\#34729\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/70bde54a2c861310eeb005e177019c96947dff09)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 70bde54a2c861310eeb005e177019c96947dff09

Requested commit: 70bde54a2c861310eeb005e177019c96947dff09

Commit: 70bde54a2c861310eeb005e177019c96947dff09

Tree: 600e6896dcf0359176a96a6bfaab3bdc34cd1026

Author: Peter Tripp

Committer: GitHub

## Message

```
ci: Lint GitHub Actions workflows with actionlint (#34729)

Added [rhysd/actionlint](https://github.com/rhysd/actionlint/) a static
checker for GitHub Actions workflow files.
Install locally with `brew install actionlint` the run with
`actionlint`.

Inspired by: https://github.com/zed-industries/zed/pull/34704 which
yielded this observation:

> In github actions: 
> 1. strings are truthy
> 2. `${{ }}` will become a string if it doesn't wrap the whole value.
>
> So `if: false && true` becomes `false`
> and `if: ${{ false && true }}` becomes `false`
> but `if: false && ${{ true }}` becomes `"false && true"` which
evaluates true
> The reason you sometimes need `${{ }}` is because YAML doesn't like
`!`
> so `if: !false` is invalid yaml
> and `if: ${{ !false }}` works just fine.

Changes:
- Add `actionlint` job
- Refactor `job_spec` job to be more readable
- Fix all `actionlint` and `shellcheck` errors in Actions workflows (62
in all)
- Add `self-mini-macos` and `self-32vcpu-windows-2022` labels to
self-hosted runners. Not strictly related, but useful if you need to
take a runner out of the rotation (since `macOS`, `self-hosted`, and
`ARM64` are auto-set and cannot be added/removed).
- Change ci.yml macos_relase to target `self-mini-macos` instead of
`bundle` which was previously deprecated.

This would've caught the error fixed in
https://github.com/zed-industries/zed/pull/34704. Here's what that [job
failure](https://github.com/zed-industries/zed/actions/runs/16376993944/job/46279281842?pr=34729)
would've looked like.

Release Notes:

- N/A
```

## Parents

- [43486c416c2be9a25322c52c71b2ed802593bcd4](https://git.cafe/gitcafe/zed/commit/43486c416c2be9a25322c52c71b2ed802593bcd4?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/70bde54a2c861310eeb005e177019c96947dff09?format=markdown)
