changeset 24:2788bffa8d0d

Add travis.yml
author Lewin Bormann <lewin@lewin-bormann.info>
date Wed, 05 Jun 2019 19:59:35 +0200
parents 4cc1c97724f2
children 3a4fbcfc9245
files .travis.yml
diffstat 1 files changed, 34 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.travis.yml	Wed Jun 05 19:59:35 2019 +0200
@@ -0,0 +1,34 @@
+os:
+  - linux
+  - osx
+dist: xenial
+sudo: false
+language: rust
+rust:
+  - stable
+  - nightly
+
+stages:
+  - name: test
+  - name: lint
+
+install: true
+
+# Default script is the "test" stage
+script: 
+  - cargo build
+  - cargo test
+
+jobs:
+  include:
+    - stage: lint
+      if: os = linux
+      rust: stable
+      install:
+        - rustup component add clippy
+        - rustup component add rustfmt
+      script:
+        - cargo fmt --all -- --check
+        - cargo clippy --all-targets --all-features -- -D warnings || true
+
+cache: cargo