Commit 3109a703 authored by Fisher, Jason C.'s avatar Fisher, Jason C.
Browse files

update CICD pipeline

parent 882c58a3
Pipeline #58470 passed with stage
in 6 minutes and 57 seconds
# .gitlab-ci.yml for inldata image: artifactory.wma.chs.usgs.gov/docker-official-mirror/rocker/geospatial:latest
image: rocker/geospatial
stages:
- check
variables: variables:
_R_CHECK_CRAN_INCOMING_: "false" _R_CHECK_CRAN_INCOMING_: "false"
_R_CHECK_SUGGESTS_ONLY: "false"
_R_CHECK_FORCE_SUGGESTS_: "true" _R_CHECK_FORCE_SUGGESTS_: "true"
APT_CACHE: "$CI_PROJECT_DIR/ci/lib/apt-cache" _R_CHECK_DONTTEST_EXAMPLES_: "false"
CRAN_MIRROR: "https://cloud.r-project.org" NOT_CRAN: "true"
R_REMOTES_NO_ERRORS_FROM_WARNINGS: "false"
R_PROFILE: "$R_HOME/etc/Rprofile.site"
R_LIBS_USER: "$CI_PROJECT_DIR/ci/lib" R_LIBS_USER: "$CI_PROJECT_DIR/ci/lib"
R_LIBS: "$CI_PROJECT_DIR/ci/lib" R_LIBS: "$CI_PROJECT_DIR/ci/lib"
BUILD_LOGS_DIR: "$CI_PROJECT_DIR/ci/logs" APT_CACHE: "$CI_PROJECT_DIR/ci/lib/apt-cache"
NOT_CRAN: "true" CRAN: "https://cloud.r-project.org"
getready: cache:
stage: .pre paths:
script: - $R_LIBS_USER
- mkdir -p $R_LIBS_USER
- mkdir -p $APT_CACHE before_script:
- R -e 'install.packages(c("knitr", "dataRetrieval", "inlmisc"), repos=Sys.getenv("CRAN_MIRROR"), lib=Sys.getenv("R_LIBS_USER"))' - mkdir -p $APT_CACHE
cache: - echo "options(Ncpus=$(nproc --all), repos=c(CRAN='$CRAN'))" >> $R_PROFILE
paths: - apt-get update && apt-get -o dir::cache::archives=$APT_CACHE install --yes --no-install-recommends qpdf pandoc pandoc-citeproc r-cran-devtools
- $R_LIBS_USER - Rscript -e "utils::install.packages('remotes')"
artifacts: - Rscript -e "remotes::install_deps(dependencies=TRUE)"
paths:
- $R_LIBS_USER
buildcheck: test:
stage: check stage: test
script: script:
- mkdir -p $BUILD_LOGS_DIR
- apt-get update
- apt-get -o dir::cache::archives=${APT_CACHE} install -y --no-install-recommends qpdf pandoc pandoc-citeproc
- R CMD build . --no-build-vignettes --no-manual - R CMD build . --no-build-vignettes --no-manual
- R -e 'devtools::check(document=FALSE, args="--no-tests", error_on="warning", check_dir=Sys.getenv("BUILD_LOGS_DIR"))' - R -e "devtools::check(document=FALSE, args='--no-tests', error_on='warning', check_dir='.', vignettes=FALSE)"
artifacts: artifacts:
paths: paths:
- $BUILD_LOGS_DIR - "*.Rcheck"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment