Skip to content

Commit

Permalink
add: deploy.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
netpyoung committed Jan 17, 2024
1 parent 32e7c08 commit 2336417
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Build and deploy GH Pages

## ref: https://github.com/peaceiris/actions-mdbook

on:
push:
branches:
- main

jobs:
build:
name: Publish site
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
- name: Setup mdBook
uses: peaceiris/actions-mdbook@v1
- name: Build mdBook
run: |
mdbook build
touch ./book/.nojekyll
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
if: ${{ github.ref == 'refs/heads/main' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./book

0 comments on commit 2336417

Please sign in to comment.