Skip to content

Merge pull request #55 from MD-Anderson-Bioinformatics/headlessjava #24

Merge pull request #55 from MD-Anderson-Bioinformatics/headlessjava

Merge pull request #55 from MD-Anderson-Bioinformatics/headlessjava #24

Workflow file for this run

on:
push:
branches:
- main
tags:
-'*'
workflow_dispatch:
name: Build documentation website
##
## This job:
## - re-renders the index.md file from index.Rmd,
## - builds pgkdown website
## - deploys pgkdown website
##
jobs:
build-pkgdown-site:
runs-on: macOS-latest
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
JAVA_VERSION: 11
steps:
- uses: actions/checkout@v3
- uses: r-lib/actions/setup-pandoc@v2
- uses: r-lib/actions/setup-r@v2
with:
extra-repositories: "https://md-anderson-bioinformatics.r-universe.dev"
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::.
needs: website
- name: Set up JDK for java ${{ env.JAVA_VERSION }}
uses: actions/setup-java@v3
with:
java-version: "${{ env.JAVA_VERSION }}"
distribution: 'temurin'
- name: Render index.Rmd (landing page for website)
run: Rscript -e 'rmarkdown::render("index.Rmd", "md_document"); print(sessionInfo())'
- name: Deploy package
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Actions"
Rscript -e 'pkgdown::deploy_to_branch(new_process = FALSE)'