pkgdown #1043
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: pkgdown | |
on: | |
pull_request: | |
push: | |
workflow_dispatch: | |
schedule: | |
- cron: '0 5 * * *' | |
jobs: | |
job1: | |
runs-on: ubuntu-latest | |
container: bioconductor/bioconductor_docker:RELEASE_3_19 | |
env: | |
R_REMOTES_NO_ERRORS_FROM_WARNINGS: true | |
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }} | |
steps: | |
- uses: actions/checkout@v3 | |
# System dependencies | |
- name: Install apt dependencies | |
run: | | |
apt-get update | |
apt-get -y upgrade | |
apt-get -y install rsync #for deploy | |
- name: Query dependencies and update old packages | |
run: | | |
repos = install.packages('remotes') | |
saveRDS(remotes::dev_package_deps(dependencies = TRUE), ".github/depends.Rds", version = 2) | |
shell: Rscript {0} | |
- name: Cache R packages | |
if: runner.os == 'Linux' | |
uses: actions/cache@v3 | |
with: | |
path: /usr/local/lib/R/site-library | |
key: ${{ runner.os }}-r-1-${{ hashFiles('.github/depends.Rds') }} | |
restore-keys: ${{ runner.os }}-r-1- | |
# This lets us augment with additional dependencies | |
- name: Install dependencies | |
run: | | |
options(repos = BiocManager::repositories()) | |
remotes::install_deps(dependencies = TRUE) | |
remotes::install_cran("rcmdcheck") | |
shell: Rscript {0} | |
- name: Check | |
env: | |
_R_CHECK_CRAN_INCOMING_REMOTE_: false | |
run: | | |
rcmdcheck::rcmdcheck(args = c("--no-manual"), error_on = "error", check_dir = "check") | |
shell: Rscript {0} | |
- name: Build pkgdown | |
run: | | |
PATH=$PATH:$HOME/bin/ Rscript -e 'pkgdown::build_site(".")' | |
- name: Deploy ð | |
uses: JamesIves/[email protected] | |
with: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
BRANCH: gh-pages # The branch the action should deploy to. | |
FOLDER: docs # The folder the action should deploy. | |