Merge pull request #11 from mom-ocean/aidanheerdegen/issue-10 #59
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: [push, pull_request] | |
env: | |
CI: "ON" # We can detect this in the build system and other vendors implement it | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ ubuntu-20.04 ] | |
# gcc_v: [8, 9] # Version of GFortran we want to use. | |
build: [ Release, Debug ] | |
runs-on: ${{ matrix.os }} | |
env: | |
# FC: gfortran-${{ matrix.gcc_v }} | |
# OMPI_FC: gfortran-${{ matrix.gcc_v }} | |
# GCC_V: ${{ matrix.gcc_v }} | |
FC: gfortran | |
OMPI_FC: gfortran | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get -yqq install csh cmake gfortran libgomp1 openmpi-bin libopenmpi-dev libnetcdf-dev libnetcdff-dev netcdf-bin | |
- name: Determing OS version | |
uses: kenchan0130/actions-system-info@master | |
id: system-info | |
- name: Set OS version | |
run: | | |
echo "Release: ${{ steps.system-info.outputs.release }}" | |
echo "os_version=${{ steps.system-info.outputs.release }}" >> $GITHUB_ENV | |
- name: Compile | |
run: | | |
cmake -S . -B build/Debug -D CMAKE_BUILD_TYPE=Debug | |
cd build/Debug && make -j |