Add CI scripts

This commit is contained in:
Matt Green 2016-10-13 22:09:34 -04:00
parent 1f5c76d194
commit 03c5096f31
3 changed files with 17 additions and 6 deletions

View File

@ -11,12 +11,6 @@ matrix:
rust: stable
env: TARGET=osx
before_install:
- export PATH="$PATH:$HOME/.cargo/bin"
install:
- bash ci/install.sh
script:
- bash ci/script.sh

14
ci/before_deploy.sh Normal file
View File

@ -0,0 +1,14 @@
# Build script shamelessly stolen from ripgrep :)
cargo build --target $TARGET --release
build_dir=$(mktemp -d 2>/dev/null || mktemp -d -t tmp)
out_dir=$(pwd)
name="${PROJECT_NAME}-${TRAVIS_TAG}-${TARGET}"
mkdir "$build_dir/$name"
cp target/$TARGET/release/watchexec "$build_dir/$name/"
pushd $build_dir
tar czf "$out_dir/$name.tar.gz" *
popd

3
ci/script.sh Normal file
View File

@ -0,0 +1,3 @@
cargo clean --target $TARGET --verbose
cargo build --target $TARGET --verbose
cargo test --target $TARGET --verbose