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
# Simple workflow for deploying static content to GitHub Pages | |
name: Deploy Latest Basilisk Documentation to Pages | |
on: | |
# Runs on pushes targeting the default branch: | |
pull_request: | |
branches: | |
- 'ci/publish-docs-to-pages-on-pr' | |
push: | |
branches: | |
- 'develop' | |
- 'ci/publish-docs-to-pages-on-pr' | |
tags: | |
- v* | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. | |
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. | |
concurrency: | |
group: "pages" | |
cancel-in-progress: false | |
jobs: | |
# Single deploy job since we're just deploying | |
deploy: | |
name: Deploy Documentation | |
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
runs-on: ubuntu-20.04 | |
strategy: | |
matrix: | |
python-version: ["3.9"] | |
steps: | |
# - name: Checkout | |
# uses: actions/checkout@v4 | |
- name: Checkout code | |
uses: nschloe/action-checkout-with-lfs-cache@v1 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Cache conan packages | |
id: cache-conan | |
uses: actions/cache@v3 | |
env: | |
cache-name: cache-conan-packages | |
with: | |
# conan cache files are stored in `~/.conan` on Linux/macOS | |
path: ~/.conan | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('conanfile.py') }} | |
restore-keys: | | |
${{ runner.os }}-build-${{ env.cache-name }}- | |
- name: Cache pip modules | |
id: cache-pip | |
uses: actions/cache@v3 | |
env: | |
cache-name: cache-pip-modules | |
with: | |
path: ~/.cache/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} | |
restore-keys: | | |
${{ runner.os }}-pip- | |
- name: "Install swig and cmake" | |
run: sudo apt-get update && sudo apt-get install build-essential cmake gtk2.0 libgtk2.0-dev ninja-build swig -y | |
- name: "Install python packages" | |
run: sudo apt-get install python3-setuptools python3-tk | |
- name: "Create virtual Environment" | |
run: | | |
python${{ matrix.python-version }} -m venv .venv | |
source .venv/bin/activate | |
echo "VIRTUAL ENV:" $VIRTUAL_ENV | |
- name: "Install wheel and conan package" | |
run: source .venv/bin/activate && pip3 install wheel conan==1.61.0 pytest datashader holoviews pytest-xdist | |
- name: "Build basilisk" | |
run: source .venv/bin/activate && python3 conanfile.py --opNav False --vizInterface False | |
- name: "Run Python Tests" | |
run: | | |
source .venv/bin/activate | |
cd src && pytest -n auto -m "not scenarioTest" --junitxml=../junit/test-results-${{ matrix.python-version }}.xml | |
# - name: "Build Documentation" | |
# run: | | |
# source .venv/bin/activate | |
- id: deployment | |
uses: sphinx-notes/pages@v3 | |
with: | |
checkout: false | |
requirements_path: ./docs/source/bskPkgOptions.txt | |
sphinx_version: 4.5.0 | |
# - name: Setup Pages | |
# uses: actions/configure-pages@v5 | |
# - name: Upload artifact | |
# uses: actions/upload-pages-artifact@v3 | |
# with: | |
# # Upload documentation HTML | |
# path: "docs/build/html" | |
# - name: Deploy to GitHub Pages | |
# id: deployment | |
# uses: actions/deploy-pages@v4 |