mirror of
https://github.com/allthingslinux/tux.git
synced 2024-10-02 16:43:12 +00:00
31 lines
676 B
YAML
31 lines
676 B
YAML
name: 'Linting'
|
|
on: [ push, pull_request ]
|
|
|
|
permissions:
|
|
contents: write
|
|
issues: write
|
|
pull-requests: write
|
|
|
|
jobs:
|
|
Linting:
|
|
runs-on: ubuntu-20.04
|
|
steps:
|
|
- name: 'Checkout Repository'
|
|
uses: actions/checkout@v4
|
|
|
|
# Install Python
|
|
- name: Setup Python
|
|
uses: actions/setup-python@v4
|
|
with:
|
|
python-version: 3.11
|
|
|
|
# Install Ruff
|
|
- name: Install Ruff
|
|
run: sudo snap install ruff
|
|
|
|
# Run Ruff linter
|
|
- name: Run Ruff format
|
|
run: ruff format && ruff check . --fix
|
|
- uses: stefanzweifel/git-auto-commit-action@v4
|
|
with:
|
|
commit_message: 'style fixes by ruff'
|