pre-commit autoupdate #507
Workflow file for this run
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: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: | |
- main | |
jobs: | |
standard: | |
strategy: | |
fail-fast: false | |
matrix: | |
runs-on: [ubuntu-latest, macos-latest, windows-latest] | |
include: | |
- runs-on: ubuntu-latest | |
config: -DCMAKE_BUILD_TYPE=Release -DBUILD_ALL=1 | |
- runs-on: macos-latest | |
config: -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTS=1 | |
- runs-on: windows-latest | |
config: -DCMAKE_BUILD_TYPE=Release -DBUILD_ALL=1 -G Ninja | |
defaults: | |
run: | |
shell: bash -l {0} | |
name: ${{ matrix.runs-on }} • x64 ${{ matrix.args }} | |
runs-on: ${{ matrix.runs-on }} | |
steps: | |
- name: Basic GitHub action setup | |
uses: actions/checkout@v3 | |
- name: Set conda environment | |
uses: mamba-org/provision-with-micromamba@main | |
with: | |
environment-file: environment.yaml | |
environment-name: myenv | |
cache-env: true | |
- name: Set dummy version | |
run: echo "SETUPTOOLS_SCM_PRETEND_VERSION=0.0" >> $GITHUB_ENV | |
- name: Configure using CMake | |
run: cmake -Bbuild ${{ matrix.config }} | |
- name: Build doxygen-docs | |
if: runner.os == 'Linux' | |
working-directory: build | |
run: | | |
make html | |
cat doxygen_warnings.log | |
- name: Require minimal documentation | |
if: runner.os == 'Linux' | |
working-directory: build | |
run: if grep -q "not documented" doxygen_warnings.log ; then exit 1; fi | |
- name: Build sphinx-docs | |
if: runner.os == 'Linux' | |
working-directory: docs | |
run: make html | |
- name: Build C++ | |
if: runner.os != 'Windows' | |
working-directory: build | |
run: cmake --build . | |
- name: Run C++ | |
if: runner.os != 'Windows' | |
working-directory: build | |
run: ctest --output-on-failure | |
- name: Build and install Python module | |
run: python -m pip install . -v | |
- name: Run Python tests | |
run: python -m unittest discover tests | |
- name: Run examples (statics) | |
working-directory: docs/examples/statics | |
run: | | |
python fixed-displacement_elastic.py | |
python fixed-displacement_elastic_manual-partition.py | |
python partial-periodic_elastic.py | |
python periodic_elastoplastic.py | |
python periodic_elastoplastic_finite-strain.py |