From f46e6994204a45e3385c67fa03cc78da42551c8e Mon Sep 17 00:00:00 2001 From: Marco D'Aleo Date: Sun, 16 Nov 2025 07:04:13 +0000 Subject: [PATCH] Add more checks on pre-commit-config, add CI workflow --- .github/workflows/ci.yml | 30 ++++++++++++++++++++++++++++++ .pre-commit-config.yaml | 2 ++ 2 files changed, 32 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..42d875d --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,30 @@ +name: CI + +on: + push: + pull_request: + +jobs: + precommit-and-security: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.13" + + - name: Install pre-commit + run: pip install pre-commit + + - name: Run pre-commit hooks + uses: pre-commit/action@v3.0.1 + + - name: Install pip-audit + run: pip install pip-audit + + - name: Run pip-audit + run: pip-audit diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 56e09e9..dfce977 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -17,3 +17,5 @@ repos: hooks: - id: trailing-whitespace - id: end-of-file-fixer + - id: check-yaml + - id: check-toml