nim-rocksdb/.travis.yml

65 lines
1.7 KiB
YAML

language: c
cache: ccache
matrix:
include:
# Build and test against the master (stable) and devel branches of Nim
# Build and test using both gcc and clang
# For faster testing we don't test clang on linux, only on macOS
- os: linux
env:
- CHANNEL=stable
# - CHANNEL=devel
compiler: gcc
sudo: required
services:
- docker
before_install:
# RocksDB is packaged for Ubuntu 16.04+ or Debian Stretch only
# Travis only supports 14.04 at the moment
- docker pull statusteam/nim-base
## Travis OSX version is too old and does not have rocksdb
- os: osx
env: CHANNEL=stable
compiler: clang
addons:
homebrew:
packages:
- rocksdb
#allow_failures:
## Ignore failures when building against the devel Nim branch
## Also ignore OSX, due to very long build time for Travis
#- env: CHANNEL=devel
#- os: osx
fast_finish: true
install:
- if [ $TRAVIS_OS_NAME = osx ]; then
export CHOOSENIM_NO_ANALYTICS=1;
curl https://nim-lang.org/choosenim/init.sh -sSf > init.sh;
sh init.sh -y;
export PATH=~/.nimble/bin:$PATH;
echo "export PATH=~/.nimble/bin:$PATH" >> ~/.profile;
choosenim $CHANNEL;
fi;
- if [ $TRAVIS_OS_NAME = linux ]; then
docker run statusteam/nim-base nim --version;
fi;
script:
- if [ $TRAVIS_OS_NAME = osx ]; then
nimble refresh;
nimble test;
fi;
- if [ $TRAVIS_OS_NAME = linux ]; then
docker run -v "$(pwd):/project" -w /project statusteam/nim-base run "apt-get -qq update && apt-get install -y librocksdb-dev && nimble install -y && nimble test";
fi;
branches:
except:
- gh-pages