1717 id : changes
1818 with :
1919 filters : " .github/file-filter.yml"
20+
21+ github :
22+ name : Github
23+ if : needs.file-changes.outputs.checkall == 'true'
24+ needs : file-changes
25+ strategy :
26+ matrix :
27+ os : ['ubuntu', 'macos']
28+ mpi : ['mpi']
29+ precision : ['']
30+ debug : ['debug', 'no-debug']
31+ intel : [true, false]
32+ exclude :
33+ - os : macos
34+ intel : true
35+
36+ include :
37+ - os : ubuntu
38+ mpi : no-mpi
39+ precision : single
40+ debug : no-debug
41+ intel : false
42+
43+ fail-fast : false
44+ continue-on-error : true
45+ runs-on : ${{ matrix.os }}-latest
46+
47+ steps :
48+ - name : Clone
49+ uses : actions/checkout@v4
50+
51+ - name : Setup MacOS
52+ if : matrix.os == 'macos'
53+ run : |
54+ brew update
55+ brew upgrade
56+ brew install coreutils python cmake fftw hdf5 gcc@14 boost open-mpi
57+ echo "FC=gfortran-14" >> $GITHUB_ENV
58+ echo "BOOST_INCLUDE=/opt/homebrew/include/" >> $GITHUB_ENV
59+
60+ - name : Setup Ubuntu
61+ if : matrix.os == 'ubuntu' && matrix.intel == false
62+ run : |
63+ sudo apt update -y
64+ sudo apt install -y cmake gcc g++ python3 python3-dev hdf5-tools \
65+ libfftw3-dev libhdf5-dev openmpi-bin libopenmpi-dev
66+
67+ - name : Setup Ubuntu (Intel)
68+ if : matrix.os == 'ubuntu' && matrix.intel == true
69+ run : |
70+ wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
71+ sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB
72+ sudo add-apt-repository "deb https://apt.repos.intel.com/oneapi all main"
73+ sudo apt-get update
74+ sudo apt-get install -y intel-oneapi-compiler-fortran intel-oneapi-mpi intel-oneapi-mpi-devel
75+ source /opt/intel/oneapi/setvars.sh
76+ printenv >> $GITHUB_ENV
77+
78+
79+ - name : Build
80+ run : |
81+ /bin/bash mfc.sh test --dry-run -j $(nproc) --${{ matrix.debug }} --${{ matrix.mpi }} --${{ matrix.precision }}
82+
83+ - name : Test
84+ run : |
85+ /bin/bash mfc.sh test --max-attempts 3 -j $(nproc) $OPT1 $OPT2
86+ env :
87+ OPT1 : ${{ matrix.mpi == 'mpi' && '--test-all' || '' }}
88+ OPT2 : ${{ matrix.debug == 'debug' && '-% 20' || '' }}
89+
2090 self :
2191 name : Self Hosted
2292 if : github.repository == 'MFlowCode/MFC' && needs.file-changes.outputs.checkall == 'true'
58128 if : always()
59129 with :
60130 name : logs-${{ strategy.job-index }}-${{ matrix.device }}
61- path : test-${{ matrix.device }}.out
131+ path : test-${{ matrix.device }}.out
0 commit comments