Skip to content

Commit

Permalink
fix #45: Github actions to publish on Pages
Browse files Browse the repository at this point in the history
  • Loading branch information
ccarouge committed Mar 28, 2023
1 parent 9edfada commit a579e9a
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/build_and_preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Build and deploy PR preview

on:
pull_request:
types:
- opened
- reopened
- synchronize
- closed

concurrency:
group: preview-${{ github.ref }}
cancel-in-progress: true

jobs:
build_and_deploy_preview:
runs-on: ubuntu-latest
steps:
- name: Checkout # Necessary to access local action
uses: actions/checkout@v3

- name: Build docs
uses: ./.github/actions/build

- name: Deploy preview
uses: rossjrw/[email protected]
with:
source-dir: documentation/site
25 changes: 25 additions & 0 deletions .github/workflows/build_and_publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Build and publish docs

on:
push:
branches:
- master

jobs:
build_and_deploy_docs:
concurrency: ci-${{ github.ref }}
runs-on: ubuntu-latest
steps:
- name: Checkout # Necessary to access local action
uses: actions/checkout@v3

- name: Build docs
uses: ./.github/actions/build

- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
branch: gh-pages # default
folder: documentation/site
clean-exclude: pr-preview/ # don't overwrite previews

0 comments on commit a579e9a

Please sign in to comment.