push-status-to-discord-action/.forgejo/workflows/ci.yml
Marc Cataford d102b907ec
Some checks failed
/ Static analysis (push) Failing after 44s
/ Dynamic analysis (push) Failing after 49s
ci: add static+dynamic analysis steps on push
fix: yaml linting

fix: python linting

fix: python formatting
2024-07-27 15:34:15 -04:00

38 lines
1 KiB
YAML

---
on: [push] # yamllint disable-line rule:truthy
jobs:
static-analysis:
name: Static analysis
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Yaml formatting
id: yaml-format
run: pipx run yamllint .
continue-on-error: true
- name: Python formatting
id: python-format
run: pipx run black . --check
continue-on-error: true
- name: Job status
if: |
${{ steps.yaml-format.outcome != 'success' }} ||
${{ steps.python-format.outcome != 'success' }}
run: exit 1
dynamic-analysis:
name: Dynamic analysis
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install dependencies
run: |
pip install -r ./requirements.txt
pipx install pylint
- name: Python linting
id: python-linting
run: pylint **/*.py
continue-on-error: true
- name: Job status
if: ${{ steps.python-linting.outcome != 'success' }}
run: exit 1