Skip to content

Commit

Permalink
Previews for PRs (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
greimel authored Jul 29, 2022
1 parent 431f422 commit 0e1b13b
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 2 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/CommentPR.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Comment Artifacts
on:
workflow_run:
workflows: [Export & Deploy Notebooks]
types: [completed]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
artifacts-url-comments:
name: add artifact links to pull request and related issues job
runs-on: ubuntu-latest
continue-on-error: true
steps:
- uses: tonyhallett/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
prefix: Here are the build results
suffix: Artifacts will only be retained for 90 days.
format: name
addTo: pull
13 changes: 11 additions & 2 deletions .github/workflows/ExportNotebooks.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: Export Pluto notebooks & Deploy
name: Export & Deploy Notebooks
on:
pull_request:
push:
branches:
- main
Expand Down Expand Up @@ -40,8 +41,16 @@ jobs:
include("generate.jl")
'
working-directory: generate
- name: Build and Deploy

- name: Upload artifacts
uses: actions/upload-artifact@v2
with:
name: website
path: ./website/__site

- name: Deploy to gh-pages
uses: JamesIves/github-pages-deploy-action@releases/v3
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master'
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages
Expand Down

0 comments on commit 0e1b13b

Please sign in to comment.