Skip to content

ci: deploy webr repository on github pages #1

ci: deploy webr repository on github pages

ci: deploy webr repository on github pages #1

Workflow file for this run

on:
push:
branches: [main]
workflow_dispatch:
name: Build WASM R package repository
jobs:
build:
runs-on: ubuntu-latest
container: ghcr.io/r-wasm/webr:main
steps:
# https://github.com/actions/checkout
- uses: actions/checkout@v3
# https://github.com/r-wasm/actions
- name: Build wasm packages
uses: r-wasm/actions/build-wasm-packages@v1
with:
strip: c("demo", "doc", "examples", "help", "html", "include", "tests", "vignette")
deploy:
name: Deploy to GitHub pages
needs: build
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
# https://github.com/actions/checkout
- uses: actions/checkout@v3
# https://github.com/r-wasm/actions
- name: Download wasm artifacts
uses: r-wasm/actions/download-wasm-artifacts@v1
with:
repo-path: _site
image-path: _site
# https://github.com/actions/upload-pages-artifact
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v2
# https://github.com/actions/deploy-pages
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2