pr template (#48) #40
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: Publish | |
on: | |
push: | |
branches: | |
main | |
workflow_dispatch: | |
jobs: | |
build: | |
name: Build, Test and Deploy | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write # To push a branch | |
pull-requests: write # To create a PR from that branch | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Setup rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
- name: Install mdbook if needed | |
run: | | |
(test -x $HOME/.cargo/bin/mdbook || cargo install --vers "^0.4" mdbook) | |
cargo install mdbook-reading-time | |
cargo install mdbook-github-authors | |
- name: Build books | |
run: | | |
# mdbook build books/fundamentals | |
# mdbook build books/cv | |
mdbook build books/nlp | |
# mdbook build books/rl | |
# mdbook build books/responsible_ai | |
# mdbook build books/fl | |
- name: Copy static assets to build folder | |
run: | | |
cp -r static/. pocket_references/ | |
- name: Deploy to github pages | |
uses: JamesIves/[email protected] | |
with: | |
branch: gh-pages # The branch the action should deploy to. | |
folder: pocket_references # The folder the action should deploy. |