2023-09-22 06:12:21 +00:00
|
|
|
name: Test
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
Test:
|
|
|
|
name: pre-commit
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: 💾 Check out repository
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
|
|
|
|
- name: 🪝 Cache pre-commit hooks
|
|
|
|
uses: actions/cache@v3
|
|
|
|
with:
|
|
|
|
path: ~/.cache/pre-commit
|
|
|
|
key: "pre-commit-${{ runner.os }}-${{ hashFiles('.pre-commit-config.yaml')
|
|
|
|
}}"
|
|
|
|
|
|
|
|
- name: ✨ Install pre-commit
|
|
|
|
shell: bash
|
|
|
|
run: python3 -m pip install pre-commit
|
|
|
|
|
|
|
|
- name: 🔥 Test
|
2024-01-06 16:36:42 +00:00
|
|
|
run: pre-commit run --show-diff-on-failure --all-files
|
2023-09-22 06:12:21 +00:00
|
|
|
|
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
|
|
cancel-in-progress: false
|