From c436613ebbfe4d02f6d69bd138706890cc6b2190 Mon Sep 17 00:00:00 2001 From: Kyle Baron Date: Wed, 4 Sep 2019 08:51:15 -0500 Subject: [PATCH] travis --- .travis.yml | 19 +++++++++++++++++++ Makefile | 12 ++++++++---- 2 files changed, 27 insertions(+), 4 deletions(-) create mode 100644 .travis.yml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..ded7953 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,19 @@ +# R for travis: see documentation at https://docs.travis-ci.com/user/languages/r + +language: R +sudo: false +dist: trusty +cache: packages + +warnings_are_errors: false + +env: + global: + - R_KEEP_PKG_SOURCE=yes + - _R_S3_METHOD_LOOKUP_BASEENV_AFTER_GLOBALENV_=true + - _R_S3_METHOD_LOOKUP_USE_TOPENV_AS_DEFENV_=true + - _R_CHECK_FORCE_SUGGESTS=0 + +script: + - export _R_CHECK_FORCE_SUGGESTS_=0 + - make travis diff --git a/Makefile b/Makefile index e696ac9..5560ce2 100644 --- a/Makefile +++ b/Makefile @@ -9,6 +9,10 @@ CHKDIR=. ## Set libPaths: export R_LIBS=${LIBDIR} +travis: + make build + R CMD check ${TARBALL} --as-cran + test: Rscript -e 'library(testthat)' -e 'test_file("tests/testthat.R")' @@ -18,7 +22,7 @@ rhub: cran: make doc make build - R CMD CHECK ${TARBALL} --as-cran + R CMD check ${TARBALL} --as-cran covr: Rscript inst/covr/covr.R @@ -39,15 +43,15 @@ build: R CMD build --md5 $(PKGDIR) install: - R CMD INSTALL --install-tests ${TARBALL} + R CMD install --install-tests ${TARBALL} install-build: - R CMD INSTALL --build --install-tests ${TARBALL} + R CMD install --build --install-tests ${TARBALL} check: make doc make build - R CMD CHECK ${TARBALL} -o ${CHKDIR} + R CMD check ${TARBALL} -o ${CHKDIR} readme: Rscript -e 'rmarkdown::render("README.Rmd")'