Skip to content

Commit

Permalink
Add pre-commit hooks
Browse files Browse the repository at this point in the history
As part of this, add a new GitHub Actions lint workflow to run the
pre-commit as well on every PR and merge.
  • Loading branch information
jmmv committed Nov 3, 2023
1 parent 894867d commit ab812f4
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 1 deletion.
11 changes: 11 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Lint

on: [push, pull_request]

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt-get install pre-commit
- run: pre-commit run -a
15 changes: 15 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: check-merge-conflict
- id: check-yaml
- id: detect-private-key
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/jlebar/pre-commit-hooks.git
rev: 62ca83ba4958da48ea44d9f24cd0aa58633376c7
hooks:
- id: do-not-submit
2 changes: 1 addition & 1 deletion INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ To build and install the source package, you must follow these steps:

2. Build the sources to generate the binaries and scripts. Run `make` on
the sources' top directory after configuring them.

3. Check that the library works before installation by running `make check`.

4. Install the library by running `make install'`. You may need to become
Expand Down
Empty file modified site/build.sh
100755 → 100644
Empty file.

0 comments on commit ab812f4

Please sign in to comment.