Skip to content

Create README.md

Create README.md #11

# use custom logic to compile and github-pages deployment
# just run script/compile_all_tutorial.py and script/render_all.py and the compiled files will be in the tutorial/build directory
name: Compile Articles
on:
push:
branches:
- main
permissions:
contents: write
pages: write
id-token: write
# 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:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.12
uses: actions/setup-python@v2
with:
python-version: 3.12
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: gitsubmodule
run: git submodule update --init --recursive
- name: Compile articles
run: python script/compile_all_tutorial.py
- name: Render articles
run: python script/render_all.py
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
path: "tutorial/build/"
# Deployment job
deploy:
environment:
name: github-pages
url: ${{steps.deployment.outputs.page_url}}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2