Repository navigation
docs(pro): add the StackHawk connector page #26848
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: Ruff Linter | |
| on: | |
| workflow_dispatch: | |
| # called by unit-tests.yml as a gate: nothing else runs until ruff passes | |
| workflow_call: | |
| # push is for the release lines: it is what lints the merged result after a | |
| # pull request lands. Unfiltered it also fired on every push to every PR | |
| # branch, doubling up with the pull_request trigger below on the same commit. | |
| push: | |
| branches: | |
| - master | |
| - dev | |
| - release/** | |
| - hotfix/** | |
| pull_request: | |
| # A merge queue tests each speculative merge commit and waits for the required | |
| # status checks to report against it. `ruff-linting` is a required check, so it | |
| # has to be produced on merge_group events too -- otherwise the queue waits for | |
| # a context that is never going to appear, with no error to say why. | |
| # | |
| # This trigger must live here rather than relying on the nested call from | |
| # unit-tests.yml: a called workflow's context is prefixed with the caller's job | |
| # name, so that path reports something other than `ruff-linting` and would not | |
| # satisfy the requirement. | |
| merge_group: | |
| jobs: | |
| ruff-linting: | |
| # Release PRs and merge-backs are merged without waiting for CI. PR: a | |
| # release/merge-* head AND the release-management label. | |
| # Push: such a branch, or GitHub's merge commit for such a PR (a push has | |
| # no labels, so the branch name is the only signal). | |
| if: >- | |
| ${{ !( | |
| (startsWith(github.event_name, 'pull_request') && startsWith(github.head_ref, 'release/merge-') && contains(github.event.pull_request.labels.*.name, 'release-management')) | |
| || (github.event_name == 'push' && (startsWith(github.ref_name, 'release/merge-') || (startsWith(github.event.head_commit.message, 'Merge pull request') && contains(github.event.head_commit.message, '/release/merge-')))) | |
| ) }} | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - name: Install Ruff Linter | |
| run: pip install -r requirements-lint.txt | |
| - name: Run Ruff Linter | |
| run: ruff check --output-format=github . |