-
Notifications
You must be signed in to change notification settings - Fork 296
41 lines (36 loc) · 1.05 KB
/
codecheckWF.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: codecheckCI
on:
workflow_call:
env:
# on CI, better dump stack trace in case there is an error
PLUMED_STACK_TRACE: yes
# use two threads for openMP tests
PLUMED_NUM_THREADS: 2
# these are used to build required packages
CC: gcc
CXX: g++
jobs:
codecheck:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Set path
run: |
echo "$HOME/opt/bin" >> $GITHUB_PATH
- name: Install requirements
run: |
.ci/install.cppcheck 2.13.4
# it is important that this is the same version used to generate the actual ./configure
.ci/install.autoconf 2.69
- name: Build astyle
run: |
make -j 4 -C astyle
- name: Checking code
run: |
# this is required so as to have all the include files in place
# notice that this is done automatically in build
# first make sure that dirslinks are generated for all modules
./configure --enable-modules=all
# then generate the links
make -C src/lib/ dirslinks
make codecheck