| @@ -9,34 +9,31 @@ name: Matrix CI | |||||
| on: [push, pull_request] # yamllint disable-line rule:truthy | on: [push, pull_request] # yamllint disable-line rule:truthy | ||||
| permissions: | |||||
| contents: read | |||||
| jobs: | jobs: | ||||
| yamllint: | |||||
| name: yamllint | |||||
| runs-on: ubuntu-latest | |||||
| steps: | |||||
| - name: Check out | |||||
| uses: actions/checkout@v6 | |||||
| - name: Run yamllint | |||||
| uses: frenck/action-yamllint@v1.5.0 | |||||
| ansible-lint: | |||||
| name: ansible-lint | |||||
| prek: | |||||
| name: Run prek hooks | |||||
| runs-on: ubuntu-latest | runs-on: ubuntu-latest | ||||
| container: | |||||
| image: docker.io/archlinux:base-devel | |||||
| steps: | steps: | ||||
| # git must be installed before checkout so it does a proper clone | |||||
| # (with .git directory) instead of a tarball download. | |||||
| - name: Install git | |||||
| run: pacman -Sy --noconfirm git | |||||
| - name: Check out | - name: Check out | ||||
| uses: actions/checkout@v6 | uses: actions/checkout@v6 | ||||
| - name: Run ansible-lint | |||||
| uses: ansible/ansible-lint@v26.3.0 | |||||
| with: | |||||
| args: "roles/custom" | |||||
| setup_python: "true" | |||||
| working_directory: "" | |||||
| requirements_file: requirements.yml | |||||
| precommit: | |||||
| name: Run pre-commit | |||||
| runs-on: ubuntu-latest | |||||
| steps: | |||||
| - name: Checkout code | |||||
| uses: actions/checkout@v6 | |||||
| - name: Run pre-commit | |||||
| uses: pre-commit/action@v3.0.1 | |||||
| - name: Install dependencies | |||||
| run: pacman -S --noconfirm --needed just mise python | |||||
| - name: Run prek hooks | |||||
| run: | | |||||
| # The checkout action sets safe.directory using its own bundled | |||||
| # git, which is separate from the pacman-installed git that prek uses. | |||||
| git config --global --add safe.directory "$GITHUB_WORKSPACE" | |||||
| just prek-run-on-all | |||||