Docs #15
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: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
schedule: | |
# Run every Sunday at midnight | |
- cron: '0 0 * * 0' | |
defaults: | |
run: | |
shell: bash -l {0} | |
jobs: | |
build: | |
name: ${{ matrix.name }} | |
runs-on: ubuntu-22.04 | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
# Latest supported versions | |
- name: Linux (CUDA 12) | |
steps: | |
- name: Check out | |
uses: actions/checkout@v2 | |
with: | |
submodules: recursive | |
- name: Show dependency file | |
run: cat environment.yml | |
- name: Install Mamba | |
uses: mamba-org/setup-micromamba@v1 | |
with: | |
environment-file: environment.yml | |
cache-environment: false | |
cache-downloads: true | |
- name: List environment | |
run: | | |
micromamba activate libmobility | |
micromamba list | |
- name: Configure and compile the library | |
run: | | |
micromamba activate libmobility | |
mkdir build && cd build | |
cmake -DCMAKE_VERBOSE_MAKEFILE=yes -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX .. | |
make -j3 all install | |
- name: Try to import libMobility | |
run: | | |
micromamba activate libmobility | |
python -c "import libMobility" | |
python -c "from libMobility import DPStokes, PSE, NBody, SelfMobility" | |
- name: Install docs dependencies | |
run: | | |
pip install -r docs/requirements.txt | |
shell: bash -el {0} | |
- name: Build Sphinx Documentation | |
run: | | |
cd docs | |
make html | |
shell: bash -el {0} |