Fix/tensorflow version #13
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: Build Documentation | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- '*' | |
pull_request: | |
branches: | |
- main | |
workflow_dispatch: | |
jobs: | |
build-python-docs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: Install Poetry | |
uses: abatilo/actions-poetry@v3 | |
with: | |
poetry-version: 'latest' | |
- name: Install Dependencies | |
run: | | |
cd imspy | |
poetry install | |
- name: Build Documentation | |
run: | | |
cd imspy | |
mkdir -p docs/source/_static # Create the static folder if it doesn't exist | |
poetry run sphinx-build docs/source/ docs/build/html | |
- name: Deploy to GitHub Pages (dev documentation) | |
if: github.ref == 'refs/heads/main' | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: imspy/docs/build/html | |
destination_dir: main/imspy | |
- name: Deploy to GitHub Pages (release documentation) | |
if: startswith(github.ref, 'refs/tags/') | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: imspy/docs/build/html | |
destination_dir: '${{ github.ref_name }}/imspy' | |
build-rust-docs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v4 | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
- name: Build Documentation | |
run: | | |
rustup update | |
cargo doc --no-deps -p mscore -p rustdf -p rustms | |
- name: Deploy to GitHub Pages (dev documentation) | |
if: github.ref == 'refs/heads/main' | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: target/doc | |
destination_dir: main | |
- name: Deploy to GitHub Pages (release documentation) | |
if: startswith(github.ref, 'refs/tags/') | |
uses: peaceiris/actions-gh-pages@v4 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: target/doc | |
destination_dir: '${{ github.ref_name }}' |