deuxfleurs 0.1.0

Viewer for geometry processing data (surface meshes, point clouds, scalar field...)
Documentation
name: Documentation
on:
  push:
    branches:
      - main

jobs:
  docs:
    permissions:
      contents: write
    name: Documentation
    runs-on: ubuntu-latest
    steps:
      - name: Checkout source code
        uses: actions/checkout@v2
        with:
          persist-credentials: false

      - name: Install Rust
        uses: actions-rs/toolchain@v1
        with:
          profile: minimal
          toolchain: stable
          override: true

      #- name: Install system packages
      #  run: |
      #    sudo apt-get update
      #    sudo apt-get install libglib2.0-dev libcairo2-dev libgdk-pixbuf-2.0-dev libatk1.0-0 libpango1.0-dev libatk-bridge2.0-dev libgtk-3-dev

      - name: Build documentation
        run: RUSTDOCFLAGS="--cfg docsrs" cargo +nightly doc --all-features

      - name: Finalize documentation
        run: |
          CRATE_NAME=$(echo '${{ github.repository }}' | tr '[:upper:]' '[:lower:]' | cut -f2 -d"/")
          echo "<meta http-equiv=\"refresh\" content=\"0; url=${CRATE_NAME/-/_}\">" > target/doc/index.html
          touch target/doc/.nojekyll

      - name: Upload as artifact
        uses: actions/upload-artifact@v4
        with:
          name: Documentation
          path: target/doc

      - name: Deploy
        uses: JamesIves/github-pages-deploy-action@v4
        with:
          #   ACCESS_TOKEN: ${{ secrets.GH_PAT }}
          #   BRANCH: gh-pages
          folder: target/doc