aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorAlex Richardson <alexrichardson@google.com>2023-05-16 14:31:29 -0700
committerPhilipp Tomsich <philipp.tomsich@vrull.eu>2023-06-15 16:53:03 +0200
commit989f43720185e3f9a3147eb69afda5c897031570 (patch)
tree4d234e5a92c5b554022342399748730d5d80773d /.github
parent2ede5ef2e10a893e9e6b4ea2b24a6472557d9685 (diff)
downloadsail-riscv-989f43720185e3f9a3147eb69afda5c897031570.zip
sail-riscv-989f43720185e3f9a3147eb69afda5c897031570.tar.gz
sail-riscv-989f43720185e3f9a3147eb69afda5c897031570.tar.bz2
Run the pre-commit checks as part of CI
Do this before installing sail or building the model to avoid wasting CI time if these basic checks are failing.
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/compile.yml10
1 files changed, 6 insertions, 4 deletions
diff --git a/.github/workflows/compile.yml b/.github/workflows/compile.yml
index de95908..fa3d1c4 100644
--- a/.github/workflows/compile.yml
+++ b/.github/workflows/compile.yml
@@ -8,14 +8,16 @@ jobs:
steps:
- name: Install packages
run: sudo apt install -y opam zlib1g-dev pkg-config libgmp-dev z3 device-tree-compiler
- - name: Init opam
- run: opam init --disable-sandboxing -y
- - name: Install sail
- run: opam install -y sail
- name: Check out repository code
uses: actions/checkout@HEAD
with:
submodules: true
+ - name: Ensure pre-commit checks pass
+ run: pip install pre-commit && pre-commit run --all-files --show-diff-on-failure --color=always
+ - name: Init opam
+ run: opam init --disable-sandboxing -y
+ - name: Install sail
+ run: opam install -y sail
- name: Build and test simulators
run: eval $(opam env) && test/run_tests.sh
- name: Upload test results