Cache tracker URL to hostname mapping #9231
Workflow file for this run
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 - File health | |
| on: [pull_request, push] | |
| permissions: {} | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
| cancel-in-progress: ${{ github.head_ref != '' }} | |
| jobs: | |
| ci: | |
| name: Check | |
| runs-on: ubuntu-latest | |
| permissions: | |
| security-events: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v5 | |
| with: | |
| persist-credentials: false | |
| - name: Setup python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "*" | |
| - name: Check files | |
| uses: pre-commit/[email protected] | |
| - name: Check doc | |
| env: | |
| pandoc_path: "${{ github.workspace }}/../pandoc" | |
| run: | | |
| # install pandoc | |
| curl \ | |
| -L \ | |
| -o "${{ runner.temp }}/pandoc.tar.gz" \ | |
| "https://github.com/jgm/pandoc/releases/download/3.7.0.2/pandoc-3.7.0.2-linux-amd64.tar.gz" | |
| tar -xf "${{ runner.temp }}/pandoc.tar.gz" -C "${{ github.workspace }}/.." | |
| mv "${{ github.workspace }}/.."/pandoc-* "${{ env.pandoc_path }}" | |
| # run pandoc | |
| for lang in doc/*/; do | |
| "${{ env.pandoc_path }}/bin/pandoc" -f markdown -t man -s "$lang/qbittorrent.1.md" -o "$lang/qbittorrent.1" | |
| "${{ env.pandoc_path }}/bin/pandoc" -f markdown -t man -s "$lang/qbittorrent-nox.1.md" -o "$lang/qbittorrent-nox.1" | |
| done | |
| # check diff, ignore "Automatically generated by ..." part | |
| git diff -I '\.\\".*' --exit-code | |
| - name: Check GitHub Actions workflow | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| pip install zizmor | |
| IGNORE_RULEID='(.ruleId != "zizmor/template-injection") | |
| and (.ruleId != "zizmor/unpinned-uses")' | |
| IGNORE_ID='(.id != "zizmor/template-injection") | |
| and (.id != "zizmor/unpinned-uses")' | |
| zizmor \ | |
| --format sarif \ | |
| --persona auditor \ | |
| ./ \ | |
| | jq "(.runs[].results |= map(select($IGNORE_RULEID))) | |
| | (.runs[].tool.driver.rules |= map(select($IGNORE_ID)))" \ | |
| > "${{ runner.temp }}/zizmor_results.sarif" | |
| - name: Upload zizmor results | |
| uses: github/codeql-action/upload-sarif@v4 | |
| with: | |
| category: zizmor | |
| sarif_file: "${{ runner.temp }}/zizmor_results.sarif" |