Skip to content

Commit 5930aa1

Browse files
committed
Run coverity if there was any commit in the week
Signed-off-by: Simo Sorce <simo@redhat.com>
1 parent 05140b3 commit 5930aa1

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed

.github/workflows/coverity.yml

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Coverity Scan
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
schedule:
7+
- cron: '13 2 * * 0'
8+
9+
jobs:
10+
coverity:
11+
name: Coverity Scan
12+
runs-on: ubuntu-22.04
13+
steps:
14+
- name: Checkout repository
15+
uses: actions/checkout@v2
16+
- name: Install dependencies
17+
run: |
18+
sudo apt-get update
19+
sudo apt-get install -y build-essential autopoint clang gcc docbook-{xsl,xml} libxml2-utils xml-core xsltproc lib{krb5,ini-config,keyutils,popt,selinux1,systemd,verto}-dev lib{nss,socket}-wrapper python3{,-colorama} valgrind krb5-{kdc,admin-server,kdc-ldap} ldap-utils slapd apparmor-utils
20+
- name: Silence AppArmor
21+
run: sudo aa-complain $(which slapd)
22+
- name: Setup
23+
run: |
24+
autoreconf -fiv
25+
./configure
26+
- name: Check for changes
27+
run: |
28+
echo "RUN_COV=0" >> $GITHUB_ENV;
29+
DIFF=`git log --since=1week | wc -l`
30+
if [ x${DIFF} != "x0" ]; then
31+
echo "RUN_COV=1" >> $GITHUB_ENV;
32+
fi
33+
- name: Coverity Scan
34+
if: env.RUN_COV == 1
35+
uses: vapier/coverity-scan-action@v1
36+
with:
37+
project: "gssproxy"
38+
email: ${{ secrets.COVERITY_SCAN_EMAIL }}
39+
token: ${{ secrets.COVERITY_SCAN_TOKEN }}

0 commit comments

Comments
 (0)