-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
Create Build pkgdown site.yaml
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
name: Build pkgdown site | ||
|
||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build-site: | ||
runs-on: ${{ matrix.config.os }} | ||
|
||
name: ${{ matrix.config.os }} (${{ matrix.config.r }}) | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
config: | ||
- {os: ubuntu-latest, r: 'release'} | ||
|
||
env: | ||
RSPM: ${{ matrix.config.rspm }} | ||
GITHUB_PAT: ${{ secrets.GH_PAT }} | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
|
||
- name: Setup R | ||
uses: r-lib/actions/setup-r@v2 | ||
with: | ||
r-version: ${{ matrix.config.r }} | ||
http-user-agent: ${{ matrix.config.http-user-agent }} | ||
|
||
- name: Install system dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y libxml2-dev libssl-dev libcurl4-openssl-dev | ||
sudo apt-get install -y libharfbuzz-dev libfribidi-dev | ||
sudo apt-get install -y pandoc | ||
sudo apt-get install -y libudunits2-dev | ||
sudo apt-get install -y libgeos-dev libproj-dev libgdal-dev | ||
- name: Install R package dependencies | ||
run: | | ||
install.packages('remotes') | ||
remotes::install_deps(dependencies = TRUE) | ||
install.packages('devtools') | ||
devtools::install_github('inbo/fistools', auth_token = Sys.getenv("GITHUB_PAT")) | ||
shell: Rscript {0} | ||
|
||
- name: Install pkgdown | ||
run: install.packages('pkgdown') | ||
shell: Rscript {0} | ||
|
||
- name: Build pkgdown site | ||
run: pkgdown::build_site() | ||
shell: Rscript {0} | ||
|
||
- name: Commit and push changes | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
git config --global user.name 'github-actions[bot]' | ||
git config --global user.email 'github-actions[bot]@users.noreply.github.com' | ||
git add -A | ||
git commit -m 'Build pkgdown site [skip ci]' | ||
git pull --rebase origin ${{ github.head_ref }} | ||
git push origin HEAD:${{ github.head_ref }} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
pandoc: 3.1.11 | ||
pandoc: 2.9.2.1 | ||
pkgdown: 2.1.0 | ||
pkgdown_sha: ~ | ||
articles: {} | ||
last_built: 2024-07-18T12:57Z | ||
last_built: 2024-07-22T13:09Z |