From 145f7cb59c2c9c5113e947bea6a2560c12c85ab9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Georges=20Dup=C3=A9ron?= Date: Fri, 31 Mar 2017 16:31:30 +0200 Subject: [PATCH] Rewrote .travis.yml --- .travis.yml | 58 ++++++++++++++--------------------------------------- README.md | 2 +- 2 files changed, 16 insertions(+), 44 deletions(-) diff --git a/.travis.yml b/.travis.yml index 50d7680..5fd7e5b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,60 +1,32 @@ language: c - -# Based from: https://github.com/greghendershott/travis-racket - -# Optional: Remove to use Travis CI's older infrastructure. sudo: false env: global: - # Supply a global RACKET_DIR environment variable. This is where - # Racket will be installed. A good idea is to use ~/racket because - # that doesn't require sudo to install and is therefore compatible - # with Travis CI's newer container infrastructure. + # RACKET_DIR is an argument to install-racket.sh - RACKET_DIR=~/racket + - PATH="$RACKET_DIR/bin:$PATH" matrix: - # Supply at least one RACKET_VERSION environment variable. This is - # used by the install-racket.sh script (run at before_install, - # below) to select the version of Racket to download and install. - # - # Supply more than one RACKET_VERSION (as in the example below) to - # create a Travis-CI build matrix to test against multiple Racket - # versions. - #- RACKET_VERSION=6.0 - #- RACKET_VERSION=6.1 - #- RACKET_VERSION=6.1.1 - #- RACKET_VERSION=6.2 - #- RACKET_VERSION=6.3 # The dependency auto-syntax-e needs 6.3 for scribble/example + # RACKET_VERSION is an argument to install-racket.sh - RACKET_VERSION=6.4 - RACKET_VERSION=6.5 - RACKET_VERSION=6.6 + - RACKET_VERSION=6.7 + - RACKET_VERSION=6.8 + - RACKET_VERSION=RELEASE - RACKET_VERSION=HEAD -matrix: - allow_failures: -# - env: RACKET_VERSION=HEAD - fast_finish: true - before_install: -- git clone https://github.com/greghendershott/travis-racket.git ~/travis-racket -- cat ~/travis-racket/install-racket.sh | bash # pipe to bash not sh! -- export PATH="${RACKET_DIR}/bin:${PATH}" #install-racket.sh can't set for us +- curl -L https://raw.githubusercontent.com/greghendershott/travis-racket/master/install-racket.sh | bash +- raco pkg install --deps search-auto doc-coverage cover cover-codecov # or cover-coveralls install: - - raco pkg install --deps search-auto - +- raco pkg install --deps search-auto -j 2 -before_script: - -# Here supply steps such as raco make, raco test, etc. You can run -# `raco pkg install --deps search-auto` to install any required -# packages without it getting stuck on a confirmation prompt. script: - - raco test -p typed-struct-props - - if test "$RACKET_VERSION" != "6.0"; then raco setup --check-pkg-deps --pkgs typed-struct-props; fi - - raco pkg install --deps search-auto doc-coverage - - if test "$RACKET_VERSION" != "6.2" -a "$RACKET_VERSION" != "6.3"; then raco doc-coverage typed-struct-props; fi - -after_success: - - raco pkg install --deps search-auto cover cover-coveralls - - raco cover -b -f coveralls -d $TRAVIS_BUILD_DIR/coverage . +- raco test -x -p "$(basename "$TRAVIS_BUILD_DIR")" +- raco setup --check-pkg-deps --no-zo --no-launcher --no-install --no-post-install --no-docs --pkgs "$(basename "$TRAVIS_BUILD_DIR")" +- raco doc-coverage "$(basename "$TRAVIS_BUILD_DIR")" +- raco cover -s main -s test -s doc -f codecov -f html -d ~/coverage . || true +# TODO: add an option to cover to run the "outer" module too, not just the submodules. +# TODO: deploy the coverage info. \ No newline at end of file diff --git a/README.md b/README.md index 00b4245..935e2b5 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ [![Build Status,](https://img.shields.io/travis/jsmaniac/typed-struct-props/master.svg)](https://travis-ci.org/jsmaniac/typed-struct-props) -[![Coverage Status,](https://img.shields.io/coveralls/jsmaniac/typed-struct-props/master.svg)](https://coveralls.io/github/jsmaniac/typed-struct-props) +[![Coverage Status,](https://img.shields.io/codecov/c/github/jsmaniac/typed-struct-props/master.svg)](https://codecov.io/gh/jsmaniac/typed-struct-props) [![Build Stats,](https://img.shields.io/badge/build-stats-blue.svg)](http://jsmaniac.github.io/travis-stats/#jsmaniac/typed-struct-props) [![Online Documentation.](https://img.shields.io/badge/docs-online-blue.svg)](http://docs.racket-lang.org/typed-struct-props/)