CodeQL #330
This file contains 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: "CodeQL" | |
on: | |
push: | |
branches: [ "main" ] | |
paths: | |
- "**.py" | |
- "**.html" | |
- "**.toml" | |
- "**Dockerfile" | |
pull_request: | |
# The branches below must be a subset of the branches above | |
branches: [ "main" ] | |
paths: | |
- "**.py" | |
- "**.html" | |
- "**.toml" | |
- "**Dockerfile" | |
schedule: | |
- cron: '29 19 * * 5' | |
jobs: | |
sonarcloud: | |
name: SonarCloud | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis | |
- name: Run SonarCloud Scan | |
uses: SonarSource/sonarcloud-github-action@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any | |
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | |
ruff: | |
name: Ruff | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install Python | |
uses: actions/setup-python@v5 | |
with: | |
cache: pip | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install ruff | |
- name: Run Ruff | |
run: ruff check --output-format=github | |
pyright: | |
name: Pyright | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install Python | |
uses: actions/setup-python@v5 | |
with: | |
cache: pip | |
- name: Install Dependencies | |
run: pip install -r requirements.lock | |
- name: Run Pyright | |
uses: jakebailey/pyright-action@v2 |