Skip to content

UPDATE

UPDATE #43

Workflow file for this run

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
#
# See https://github.com/r-lib/actions/tree/master/examples#readme for
# additional example workflows available for the R community.
name: R Package CI for MacOS
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
permissions:
contents: read
jobs:
build:
runs-on: macos-latest
strategy:
matrix:
os: [macos-latest]
r-version: ['4.1.1']
steps:
- uses: actions/checkout@v4
- name: Install JAGS on macOS
run: brew install jags
- name: Install gcc (includes gfortran)
run: brew install gcc
- name: Ensure gfortran is in PATH
run: |
echo "/opt/homebrew/bin" >> $GITHUB_PATH
echo "/opt/homebrew/opt/gcc/bin" >> $GITHUB_PATH
- name: Check gfortran installation
run: gfortran --version
- name: Set up R ${{ matrix.r-version }}
uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.r-version }}
- name: Install TinyTeX
run: |
Rscript -e "install.packages('tinytex')"
Rscript -e "tinytex::install_tinytex()"
- name: Set CRAN mirror
run: Rscript -e 'options(repos = c(CRAN = "https://cloud.r-project.org/"))'
shell: /bin/bash -e {0}
- name: Install remotes package
run: Rscript -e 'install.packages("remotes")'
- name: Install package dependencies
run: Rscript -e 'install.packages(c("smacof", "basicspace", "vegan"), dependencies = TRUE)'
- name: Install basicspace from GitHub
env:
GITHUB_PAT: ${{ secrets.MY_GITHUB_PAT }}
run: Rscript -e 'remotes::install_github("cran/basicspace", force = TRUE)'
- name: Install other R package dependencies
run: Rscript -e 'install.packages(c("rjags", "ggplot2", "knitr"))'
- name: Install rcmdcheck package
run: Rscript -e 'install.packages("rcmdcheck")'
- name: Check
run: Rscript -e 'rcmdcheck::rcmdcheck(args = "--no-manual", error_on = "error")'
- name: Test (optional)
run: Rscript -e 'devtools::test()'
env:
R_LIBS_USER: /Users/runner/work/_temp/Library
TZ: UTC
_R_CHECK_SYSTEM_CLOCK_: FALSE
NOT_CRAN: true