Trim trailing whitespace and test on CI (#104275)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
This commit is contained in:
Hugo van Kemenade 2023-05-08 17:03:52 +03:00 committed by GitHub
parent 1f5679540c
commit d513ddee94
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 44 additions and 12 deletions

3
.github/CODEOWNERS vendored
View File

@ -7,6 +7,9 @@
# GitHub
.github/** @ezio-melotti @hugovk
# pre-commit
.pre-commit-config.yaml @hugovk @AlexWaygood
# Build system
configure* @erlend-aasland @corona10

22
.github/workflows/lint.yml vendored Normal file
View File

@ -0,0 +1,22 @@
name: Lint
on: [push, pull_request, workflow_dispatch]
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
lint:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: "3.x"
- uses: pre-commit/action@v3.0.0

7
.pre-commit-config.yaml Normal file
View File

@ -0,0 +1,7 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-yaml
- id: trailing-whitespace
types_or: [c, python, rst]