Skip to content

Commit

Permalink
Add workflow to automatically publish html slides
Browse files Browse the repository at this point in the history
  • Loading branch information
cr-xu committed Feb 19, 2024
1 parent b34236c commit 963fa5e
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/publish_website.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: publish_website

on:
push:
branches:
- main

jobs:
push_to_branch:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Setup Python
uses: actions/setup-python@v2
with:
python-version: '3.x'

- name: Install Jupyter
run: pip install notebook

- name: Export the notebook and Add files
run: |
mkdir temp
cp -r img/ temp/img/
jupyter nbconvert tutorial.ipynb --to slides
mv tutorial.slides.html temp/index.html
ls -R temp
rm -r meta-rl/
- name: Deploy
uses: s0/git-publish-subdir-action@develop
env:
REPO: self
BRANCH: website
FOLDER: temp
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 963fa5e

Please sign in to comment.