Publish Skriptey Userscripts (2026-06-21) #28
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: Secret scan | |
| # Scans commit history for leaked secrets using the gitleaks CLI binary | |
| # (MIT-licensed, free). We deliberately do NOT use gitleaks/gitleaks-action, | |
| # which requires a paid licence for org-owned repos and silently no-ops without | |
| # one. The CLI route also avoids the action's Node runtime entirely. | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| security-events: write # upload SARIF findings to the Security tab | |
| jobs: | |
| gitleaks: | |
| name: gitleaks (CLI) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| fetch-depth: 0 # full history so gitleaks can scan every commit | |
| - name: Install gitleaks CLI | |
| run: | | |
| VERSION="8.30.1" | |
| case "$(uname -m)" in | |
| x86_64) ARCH=x64 ;; | |
| aarch64 | arm64) ARCH=arm64 ;; | |
| *) echo "unsupported arch: $(uname -m)" >&2; exit 1 ;; | |
| esac | |
| curl -fsSL "https://github.com/gitleaks/gitleaks/releases/download/v${VERSION}/gitleaks_${VERSION}_linux_${ARCH}.tar.gz" \ | |
| | sudo tar -xz -C /usr/local/bin gitleaks | |
| gitleaks version | |
| - name: Scan repository history | |
| # `gitleaks git` (the modern subcommand; `detect` is deprecated/hidden | |
| # since 8.19) scans the current repo's full history by default. | |
| run: | | |
| gitleaks git \ | |
| --redact \ | |
| --report-format sarif \ | |
| --report-path gitleaks.sarif \ | |
| --exit-code 1 | |
| - name: Upload SARIF | |
| # Code scanning (SARIF upload) needs GitHub Advanced Security — free on | |
| # public repos, unavailable on private Free repos. Skip it on private | |
| # (the gitleaks scan above still fails the build on a hit); the public | |
| # mirror gets the full Security-tab upload. | |
| if: ${{ always() && github.event.repository.private == false }} | |
| uses: github/codeql-action/upload-sarif@v4 | |
| with: | |
| sarif_file: gitleaks.sarif | |
| category: gitleaks |