Skip to content

Commit

Permalink
ci: use pkgdown build script
Browse files Browse the repository at this point in the history
This change pins bslib version to 0.5.1 to keep Bootstrap 5.2.2.
Switching to a newer bslib (and Bootstrap) version requires fixing CSS.
  • Loading branch information
TymekDev committed May 8, 2024
1 parent 5e3ef7d commit 08e453d
Showing 1 changed file with 19 additions and 11 deletions.
30 changes: 19 additions & 11 deletions .github/workflows/pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,15 @@ on:
permissions:
contents: write
jobs:
main:
pkgdown:
name: Build and publish website
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Install R
uses: r-lib/actions/setup-r@v2
Expand All @@ -27,15 +29,21 @@ jobs:
- name: Install R package dependencies
uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::.
extra-packages: any::pkgdown, any::remotes, local::.

- name: Configure git
- name: Build site
shell: Rscript {0}
run: |
git config user.name "$GITHUB_ACTOR"
git config user.email "[email protected]"
source("pkgdown/build.R")
build_versioned(
repo = ".",
versions = yaml::read_yaml("pkgdown/versions.yaml"),
url = "https://appsilon.github.io/rhino",
destination = "docs"
)
- name: Build and deploy site
shell: Rscript {0}
run: pkgdown::deploy_to_branch(branch = "bot/github-pages")
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: docs
branch: bot/github-pages

0 comments on commit 08e453d

Please sign in to comment.