From eda83ac3d94b963d00889d8b150e0bfa3b11bd5e Mon Sep 17 00:00:00 2001 From: Kang Seonghoon Date: Wed, 17 Aug 2016 03:05:09 +0900 Subject: [PATCH] Tweaked Travis settings and tried to enable Appveyor CI. --- .travis.yml | 28 ++++++++++++++++++++++------ Makefile | 12 +++++++++--- README.md | 12 +++++++++--- appveyor.yml | 25 +++++++++++++++++++++++++ 4 files changed, 65 insertions(+), 12 deletions(-) create mode 100644 appveyor.yml diff --git a/.travis.yml b/.travis.yml index 56a4b57..c084159 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,18 +1,34 @@ language: rust +sudo: false +rust: + # 1.8.0 is the earliest known version that Cargo does work for the current crates.io-index repo. + # probably older versions work, but we are forced to use this as the minimum for Cargo... + - 1.8.0 + - stable + - beta + - nightly os: - linux - osx +matrix: + allow_failures: + - rust: nightly env: global: - LD_LIBRARY_PATH: /usr/local/lib - - secure: i8Ijk6g4/26e3e7+r2OeGAPSP8G8O9P50JibW1omJ0j0ixXhyhPoY2bch3CGhnOu44dI5O31IIbjJJ+iEMp29xQBvkv9YpxAI+hIzOP+XAH6GCYxUDiBVcDoWrXTj+wU6/veuvjLCunu4eRHlskrgJbZXhUVODYzJuLgsN8Ou0w= script: + # interleave building and testing in hope that it saves time - cargo build -v - - cargo build -v --features rustc-serialize - - cargo build -v --features serde - cargo test -v + - cargo build -v --features rustc-serialize - cargo test -v --features rustc-serialize + - cargo build -v --features serde - cargo test -v --features serde - - cargo doc -after_script: - - cd target && curl http://www.rust-ci.org/artifacts/put?t=$RUSTCI_TOKEN | sh +notifications: + email: false + irc: + channels: + - "irc.mozilla.org#chronotope" + template: + - "%{repository_slug}/%{branch} (%{commit} - %{author}): %{message}" + skip_join: true diff --git a/Makefile b/Makefile index b3b3e88..f4ac895 100644 --- a/Makefile +++ b/Makefile @@ -21,12 +21,18 @@ README.md: src/lib.rs awk '/^\/\/! # Chrono /{print "[Chrono][doc]",$$4}' $< | sed 's/./=/g' >> $@ echo >> $@ echo '[![Chrono on Travis CI][travis-image]][travis]' >> $@ + echo '[![Chrono on Appveyor][appveyor-image]][appveyor]' >> $@ + echo '[![Chrono on crates.io][cratesio-image]][cratesio]' >> $@ echo >> $@ - echo '[travis-image]: https://travis-ci.org/lifthrasiir/rust-chrono.png' >> $@ - echo '[travis]: https://travis-ci.org/lifthrasiir/rust-chrono' >> $@ + echo '[travis-image]: https://travis-ci.org/lifthrasiir/rust-chrono.svg?branch=master' >> $@ + echo '[travis]: https://travis-ci.org/lifthrasiir/rust-chrono/branch/master' >> $@ + echo '[appveyor-image]: https://ci.appveyor.com/api/projects/status/o83jn08389si56fy/branch/master?svg=true' >> $@ + echo '[appveyor]: https://ci.appveyor.com/project/lifthrasiir/rust-chrono/branch/master' >> $@ + echo '[cratesio-image]: https://img.shields.io/crates/v/chrono.svg' >> $@ + echo '[cratesio]: https://crates.io/crates/chrono' >> $@ awk '/^\/\/! # Chrono /,/^\/\/! ## /' $< | cut -b 5- | grep -v '^#' | \ sed 's/](\.\//](https:\/\/lifthrasiir.github.io\/rust-chrono\/chrono\//g' >> $@ - echo '[Complete Documentation][doc]' >> $@ + echo '***[Complete Documentation][doc]***' >> $@ echo >> $@ echo '[doc]: https://lifthrasiir.github.io/rust-chrono/' >> $@ echo >> $@ diff --git a/README.md b/README.md index 0d503a2..bf2852a 100644 --- a/README.md +++ b/README.md @@ -2,9 +2,15 @@ ==================== [![Chrono on Travis CI][travis-image]][travis] +[![Chrono on Appveyor][appveyor-image]][appveyor] +[![Chrono on crates.io][cratesio-image]][cratesio] -[travis-image]: https://travis-ci.org/lifthrasiir/rust-chrono.png -[travis]: https://travis-ci.org/lifthrasiir/rust-chrono +[travis-image]: https://travis-ci.org/lifthrasiir/rust-chrono.svg?branch=master +[travis]: https://travis-ci.org/lifthrasiir/rust-chrono/branch/master +[appveyor-image]: https://ci.appveyor.com/api/projects/status/o83jn08389si56fy/branch/master?svg=true +[appveyor]: https://ci.appveyor.com/project/lifthrasiir/rust-chrono/branch/master +[cratesio-image]: https://img.shields.io/crates/v/chrono.svg +[cratesio]: https://crates.io/crates/chrono Date and time handling for Rust. (also known as `rust-chrono`) It aims to be a feature-complete superset of @@ -23,7 +29,7 @@ which Chrono builts upon and should acknowledge: * Dietrich Epp's [datetime-rs](https://github.com/depp/datetime-rs) * Luis de Bethencourt's [rust-datetime](https://github.com/luisbg/rust-datetime) -[Complete Documentation][doc] +***[Complete Documentation][doc]*** [doc]: https://lifthrasiir.github.io/rust-chrono/ diff --git a/appveyor.yml b/appveyor.yml new file mode 100644 index 0000000..0d1f85b --- /dev/null +++ b/appveyor.yml @@ -0,0 +1,25 @@ +environment: + matrix: + - TARGET: 1.8.0-x86_64-pc-windows-gnu + - TARGET: stable-x86_64-pc-windows-msvc + - TARGET: stable-i686-pc-windows-msvc + - TARGET: stable-x86_64-pc-windows-gnu + - TARGET: stable-i686-pc-windows-gnu + - TARGET: nightly-x86_64-pc-windows-msvc + - TARGET: nightly-i686-pc-windows-msvc + - TARGET: nightly-x86_64-pc-windows-gnu + - TARGET: nightly-i686-pc-windows-gnu +matrix: + allow_failures: + - channel: nightly +install: + - ps: Start-FileDownload "https://static.rust-lang.org/dist/rust-${env:TARGET}.exe" -FileName "rust-install.exe" + - ps: .\rust-install.exe /VERYSILENT /NORESTART /DIR="C:\rust" | Out-Null + - ps: $env:PATH="$env:PATH;C:\rust\bin" + - rustc -vV + - cargo -vV +build_script: + # do not test all combinations, Travis will handle that + - cargo build -v --features 'serde rustc-serialize' +test_script: + - cargo test -v --features 'serde rustc-serialize'