security: harden automerge with fetch-metadata, pin actions to SHA #7
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| jobs: | |
| shell-and-security: | |
| runs-on: macos-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v6 | |
| - name: Setup Python | |
| uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v6 | |
| with: | |
| python-version: "3.x" | |
| - name: Install pre-commit | |
| run: python -m pip install --upgrade pip pre-commit | |
| - name: Pre-commit checks | |
| run: pre-commit run --all-files --show-diff-on-failure | |
| - name: Shell syntax checks | |
| run: | | |
| bash -n bootstrap.sh | |
| bash -n install.sh | |
| - name: Security scrub (working tree) | |
| run: python3 scripts/security_scrub.py --no-history |