update LR #584
Workflow file for this run
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
# The purpose of this action is to run `document()` of the roxygen2 package on each commit. | |
# If new documentation was generated, it will automatically add a commit to the current branch. | |
# This has the same effect as running `document()` locally, but | |
# * ensures it cannot be forgotten | |
# * saves setting up the development environment locally, which is especially useful for new contributors. | |
# | |
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples | |
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help | |
on: | |
pull_request: | |
paths: ["R/**", ".github/workflows"] | |
name: Document | |
jobs: | |
document: | |
runs-on: ubuntu-latest # self-hosted | |
env: | |
GITHUB_PAT: ${{ secrets.TOKEN }} | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
# extra token required to trigger github actions again on commit | |
token: ${{ secrets.TOKEN }} # BOT_GH_TOKEN | |
- name: Update system dependencies | |
run: | | |
sudo apt-get update && sudo apt-get install \ | |
libcurl4-openssl-dev -y | |
- name: Setup R | |
uses: r-lib/actions/setup-r@v2 | |
with: | |
use-public-rspm: true | |
- name: Install pak | |
run: Rscript -e "install.packages('pak', repos='https://cran.rstudio.com/')" | |
#- name: Install SpatialExperiment | |
# run: Rscript -e "pak::pkg_install('drighelli/SpatialExperiment')" | |
- name: Install Devtools | |
run: Rscript -e "pak::pkg_install('devtools')" | |
- name: Install SpatialExperiment | |
run: Rscript -e "devtools::install_github('drighelli/SpatialExperiment')" | |
- name: Install dependencies | |
uses: r-lib/actions/setup-r-dependencies@v2 | |
with: | |
dependencies: '"hard"' # do not install suggests | |
extra-packages: any::roxygen2 | |
needs: roxygen2 | |
- name: Document | |
run: roxygen2::roxygenise() | |
shell: Rscript {0} | |
- uses: stefanzweifel/git-auto-commit-action@v4 | |
with: | |
commit_message: Roxygenize |