diff --git a/.github/workflows/process.yml b/.github/workflows/process.yml index f9eafba3d..6b698a632 100644 --- a/.github/workflows/process.yml +++ b/.github/workflows/process.yml @@ -253,3 +253,29 @@ jobs: - name: Deploy GitHub pages id: deployment uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e + + examples: + # Job to make examples browser link + concurrency: + group: docs-jobs + cancel-in-progress: false + runs-on: ubuntu-latest + # depends on tracking; only runs upon merge to main + needs: tracking + if: github.ref == 'refs/heads/main' + steps: + - name: Setup python and hatch + uses: Fusion-Power-Plant-Framework/fppf-actions/setup-hatch@c6af22fc8d00be67cca53a61177301462f499fb2 + with: + python-version: ${{ env.python-version }} + - run: git config --global --add safe.directory '*' + - name: Build the JupyterLite site + run: | + jupyter lite build --contents examples/ --output-dir dist + - name: Upload artifact + uses: actions/upload-pages-artifact@v3 + with: + path: ./dist + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 1c82d4613..e534b7087 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ test = [ "filelock", "process[examples]" ] -examples = ["jupyter==1.0.0", "jupytext"] +examples = ["jupyter==1.0.0", "jupytext", "jupyterlite-core==0.7.1", "jupyterlab~=4.5.1", "notebook~=7.5.1"] plotly = ["plotly>=5.15.0,<6"] docs = [ "mkdocs>=1.1",