Skip to content

add spack-based CI build #30

add spack-based CI build

add spack-based CI build #30

Workflow file for this run

name: developer
on:
push:
branches:
- develop
pull_request:
branches:
- develop
jobs:
developer:
runs-on: ubuntu-latest
env:
FC: gfortran-11
CC: gcc-11
steps:
- name: install-dependencies
run: |
sudo apt-get update
sudo apt-get install doxygen
python3 -m pip install gcovr
- name: checkout
uses: actions/checkout@v2
with:
path: g2tmpl
submodules: true
- name: build
run: |
cd g2tmpl
mkdir build
cd build
cmake -DENABLE_DOCS=ON -DCMAKE_C_FLAGS="-g -fprofile-abs-path -fprofile-arcs -ftest-coverage -O0 -fsanitize=address -Wall -Werror" -DCMAKE_Fortran_FLAGS="-g -fprofile-abs-path -fprofile-arcs -ftest-coverage -O0 -fsanitize=address -Wall" -DCMAKE_BUILD_TYPE=Debug ..
make -j2 VERBOSE=1
- name: test
run: |
cd $GITHUB_WORKSPACE/g2tmpl/build
ctest --verbose --output-on-failure --rerun-failed
gcovr --root .. -v --html-details --exclude ../tests --exclude CMakeFiles --print-summary -o test-coverage.html
- name: upload-test-coverage
uses: actions/upload-artifact@v2
with:
name: g2tmpl-test-coverage
path: |
g2tmpl/build/*.html
g2tmpl/build/*.css