diff --git a/.github/workflows/build_and_test.yml b/.github/workflows/build_and_test.yml index 4ea34ca16..37aaed63b 100644 --- a/.github/workflows/build_and_test.yml +++ b/.github/workflows/build_and_test.yml @@ -31,7 +31,12 @@ jobs: apk update && apk add cppcheck python3-dev python3 -m pip install cmake-format clang-format==18.1.6 - # TODO: investigate how to run pre-commit with `venv` + - name: Activate virtualenv + run: | + python3 -m venv ./venv + . .venv/bin/activate + echo PATH=$PATH >> $GITHUB_ENV + - uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd # v3.0.1 - name: CMake format