Updating Config.yml and adding a folder for Projects to be added in t… #4
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: deploy-book | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- 'notebooks/**' | |
- '_config.yml' | |
- '_toc.yml' | |
- 'requirements.txt' | |
- 'index.md' | |
jobs: | |
deploy-book: | |
runs-on: ubuntu-latest | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
permissions: | |
pages: write | |
id-token: write | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python 3.11 | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.11 | |
cache: 'pip' | |
- name: Install dependencies | |
run: | | |
pip install -r requirements.txt | |
pip install jupyter-book sphinx-book-theme | |
- name: Build the book | |
run: | | |
jupyter-book config sphinx . # Generate sphinx config | |
jupyter-book build . --all # Build all files | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v2 | |
with: | |
path: "_build/html" | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v2 |