Skip to content

Commit

Permalink
Merge pull request #261 from libcheck/actions-scan-build
Browse files Browse the repository at this point in the history
Enable clang's scan-build on Github actions
  • Loading branch information
brarcher authored May 25, 2020
2 parents fafb129 + fc6490f commit ee2c73e
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,3 +110,23 @@ jobs:
run: ctest -V
- name: make install
run: sudo make install

build_linux_scanbuild:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install scan-build packages
run: sudo apt-get install -y clang-tools
- name: create configure
run: autoreconf -i
- name: configure
run: scan-build ./configure --enable-snprintf-replacement --enable-timer-replacement --disable-build-docs
- name: make
run: scan-build -o clang make
- name: check for issues
run: |
if [ -n "$(find clang -type f)" ]; then
echo "scan-build found potential issues"
find clang -type f -print -exec cat \{} \;
exit 1
fi

0 comments on commit ee2c73e

Please sign in to comment.