Skip to content

Commit 775f8fa

Browse files
committed
Add deploy preview step
1 parent 840701d commit 775f8fa

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

.github/workflows/github_pages.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ on:
55
branches:
66
- main
77
pull_request:
8+
- opened
9+
- reopened
10+
- synchronize
11+
- closed
12+
13+
concurrency: preview-${{ github.ref }}
814

915
jobs:
1016
deploy:
@@ -28,3 +34,9 @@ jobs:
2834
with:
2935
github_token: ${{ secrets.GITHUB_TOKEN }}
3036
publish_dir: ./book/book
37+
38+
- name: Deploy preview
39+
uses: rossjrw/pr-preview-action@v1
40+
if: ${{ github.ref != 'refs/heads/main' }}
41+
with:
42+
source-dir: ./book/book

0 commit comments

Comments
 (0)