Skip to content
Snippets Groups Projects
Commit 34041855 authored by Ulrik Stervbo's avatar Ulrik Stervbo
Browse files

Reformatting

parent 6bae02d3
No related branches found
No related tags found
No related merge requests found
......@@ -3,16 +3,16 @@ image: r-base:latest
stages:
- setup
- check
- coverage
- check
- coverage
variables:
RENV_PATHS_CACHE: ${CI_PROJECT_DIR}/.renv/cache
RENV_PATHS_LIBRARY: ${CI_PROJECT_DIR}/.renv/lib
CHECK_DIR: "${CI_PROJECT_DIR}/logs"
# Some tutorials will mention the use of CI_PROJECT_NAME, but CI_PROJECT_TITLE is used in the path generation
BUILD_LOGS_DIR: "${CI_PROJECT_DIR}/logs/${CI_PROJECT_TITLE}.Rcheck"
RENV_PATHS_LIBRARY: ${CI_PROJECT_DIR}/.renv/lib
CHECK_DIR: "${CI_PROJECT_DIR}/logs"
# Some tutorials will mention the use of CI_PROJECT_NAME, but CI_PROJECT_TITLE is used in the path generation
BUILD_LOGS_DIR: "${CI_PROJECT_DIR}/logs/${CI_PROJECT_TITLE}.Rcheck"
cache:
......@@ -21,23 +21,23 @@ cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- ${RENV_PATHS_CACHE}
- ${RENV_PATHS_LIBRARY}
- ${RENV_PATHS_LIBRARY}
before_script:
- 'apt-get update'
# Install needed packages. The call makes apt-get say yes to everything (-y),
# and give no output except for errors (-qq)
# Satisfy system dependencies for the R-packages
# nloptr (drc -> car -> lme4 -> nloptr) need libnlopt-dev
# systemfonts (ggplot2 -> ragg -> systemfonts) need libfontconfig1-dev
# We need 'qpdf' for checks on pdfs
- 'apt-get install -y -qq libnlopt-dev libfontconfig1-dev qpdf'
# We use the `check()` function of the devtools-package which imports the R-packages
# curl - which need `libcurl4-openssl-dev` to be installed
# openssl - which need `libssl-dev` to be installed
# xml2 - which need `libxml2-dev` to be installed
- 'apt-get install -y -qq libcurl4-openssl-dev libssl-dev libxml2-dev'
# Install needed packages. The call makes apt-get say yes to everything (-y),
# and give no output except for errors (-qq)
# Satisfy system dependencies for the R-packages
# nloptr (drc -> car -> lme4 -> nloptr) need libnlopt-dev
# systemfonts (ggplot2 -> ragg -> systemfonts) need libfontconfig1-dev
# We need 'qpdf' for checks on pdfs
- 'apt-get install -y -qq libnlopt-dev libfontconfig1-dev qpdf'
# We use the `check()` function of the devtools-package which imports the R-packages
# curl - which need `libcurl4-openssl-dev` to be installed
# openssl - which need `libssl-dev` to be installed
# xml2 - which need `libxml2-dev` to be installed
- 'apt-get install -y -qq libcurl4-openssl-dev libssl-dev libxml2-dev'
setup:
......@@ -45,8 +45,8 @@ setup:
script:
# Restore renv
- Rscript -e 'renv::restore()'
# Install devtools for the case it is not used
- Rscript -e 'install.packages(c("devtools", "covr"))'
# Install devtools for the case it is not used
- Rscript -e 'install.packages(c("devtools", "covr"))'
check:
......@@ -56,13 +56,13 @@ dependencies:
when: on_success
script:
- 'apt-get install -y -qq pandoc'
# Make sure the renv cache and lib paths are in .Rbuildignore
- echo "^.renv$" >> .Rbuildignore
- Rscript -e 'devtools::check(check_dir = Sys.getenv("CHECK_DIR"))'
# Make sure the renv cache and lib paths are in .Rbuildignore
- echo "^.renv$" >> .Rbuildignore
- Rscript -e 'devtools::check(check_dir = Sys.getenv("CHECK_DIR"))'
artifacts:
paths:
- $BUILD_LOGS_DIR/00install.out
- $BUILD_LOGS_DIR/00check.log
- $BUILD_LOGS_DIR/00check.log
expire_in: 1 week
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment