2018-11-26 12:19:40 +00:00
|
|
|
language: rust
|
2018-12-05 10:30:05 +00:00
|
|
|
cache: cargo
|
2018-12-06 20:48:21 +00:00
|
|
|
sudo: required
|
2018-12-05 10:30:05 +00:00
|
|
|
|
2018-11-26 12:19:40 +00:00
|
|
|
matrix:
|
|
|
|
allow_failures:
|
2018-12-06 13:42:16 +00:00
|
|
|
include:
|
|
|
|
# Stable channel.
|
|
|
|
- os: linux
|
|
|
|
rust: stable
|
|
|
|
env: TARGET=x86_64-unknown-linux-gnu
|
|
|
|
- os: linux
|
|
|
|
rust: stable
|
|
|
|
env: TARGET=i686-unknown-linux-gnu
|
2019-05-30 06:50:41 +00:00
|
|
|
- os: linux
|
|
|
|
rust: stable
|
|
|
|
env: TARGET=x86_64-unknown-linux-musl
|
|
|
|
- os: linux
|
|
|
|
rust: stable
|
|
|
|
env: TARGET=i686-unknown-linux-musl
|
2018-12-06 13:42:16 +00:00
|
|
|
- os: osx
|
|
|
|
rust: stable
|
|
|
|
env: TARGET=x86_64-apple-darwin
|
2018-12-17 12:32:35 +00:00
|
|
|
- os: linux
|
|
|
|
rust: stable
|
|
|
|
env:
|
|
|
|
- TARGET=arm-unknown-linux-gnueabihf
|
|
|
|
- CARGO_TARGET_ARM_UNKNOWN_LINUX_GNUEABIHF_LINKER=arm-linux-gnueabihf-gcc-4.8
|
2018-12-06 13:42:16 +00:00
|
|
|
|
|
|
|
# Beta channel.
|
2018-12-17 12:32:35 +00:00
|
|
|
# The other platforms are disabled in order to reduce the total CI time
|
2018-12-06 13:42:16 +00:00
|
|
|
- os: linux
|
|
|
|
rust: beta
|
|
|
|
env: TARGET=x86_64-unknown-linux-gnu
|
|
|
|
|
|
|
|
# Nightly channel.
|
2018-12-17 12:32:35 +00:00
|
|
|
# The other platforms are disabled in order to reduce the total CI time
|
2018-12-06 13:42:16 +00:00
|
|
|
- os: linux
|
|
|
|
rust: nightly
|
|
|
|
env: TARGET=x86_64-unknown-linux-gnu
|
|
|
|
|
|
|
|
# Minimum Rust supported channel.
|
|
|
|
- os: linux
|
2020-05-31 09:56:57 +00:00
|
|
|
rust: 1.43.1
|
2018-12-06 13:42:16 +00:00
|
|
|
env: TARGET=x86_64-unknown-linux-gnu
|
|
|
|
- os: linux
|
2020-05-31 09:56:57 +00:00
|
|
|
rust: 1.43.1
|
2018-12-06 13:42:16 +00:00
|
|
|
env: TARGET=i686-unknown-linux-gnu
|
|
|
|
- os: osx
|
2020-05-31 09:56:57 +00:00
|
|
|
rust: 1.43.1
|
2018-12-06 13:42:16 +00:00
|
|
|
env: TARGET=x86_64-apple-darwin
|
2018-12-17 12:32:35 +00:00
|
|
|
- os: linux
|
2020-05-31 09:56:57 +00:00
|
|
|
rust: 1.43.1
|
2018-12-17 12:32:35 +00:00
|
|
|
env:
|
|
|
|
- TARGET=arm-unknown-linux-gnueabihf
|
|
|
|
- CARGO_TARGET_ARM_UNKNOWN_LINUX_GNUEABIHF_LINKER=arm-linux-gnueabihf-gcc-4.8
|
2018-12-06 13:42:16 +00:00
|
|
|
|
|
|
|
# Code formatting check
|
|
|
|
- os: linux
|
|
|
|
rust: stable
|
|
|
|
# skip the global install step
|
|
|
|
install:
|
2018-12-13 15:48:50 +00:00
|
|
|
- rustup component add clippy
|
2018-12-06 13:42:16 +00:00
|
|
|
script:
|
2019-03-04 18:12:11 +00:00
|
|
|
- cargo clippy --all-features
|
2018-12-06 13:42:16 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
global:
|
|
|
|
# Default target on travis-ci.
|
|
|
|
# Used as conditional check in the install stage
|
|
|
|
- HOST=x86_64-unknown-linux-gnu
|
|
|
|
# Used on the deployment script
|
|
|
|
- PROJECT_NAME=lsd
|
|
|
|
|
|
|
|
install:
|
|
|
|
# prevent target re-add error from rustup
|
|
|
|
- if [[ $TRAVIS_OS_NAME = linux && $HOST != $TARGET ]]; then rustup target add $TARGET; fi
|
2018-12-05 10:30:05 +00:00
|
|
|
|
|
|
|
script:
|
2018-12-17 12:32:35 +00:00
|
|
|
- bash ci/script.bash
|
2018-12-06 13:42:16 +00:00
|
|
|
|
2018-12-17 12:32:35 +00:00
|
|
|
before_install:
|
|
|
|
- bash ci/before_install.bash
|
2018-12-06 13:42:16 +00:00
|
|
|
|
|
|
|
before_deploy:
|
2018-12-17 12:32:35 +00:00
|
|
|
- bash ci/before_deploy.bash
|
2018-12-06 13:42:16 +00:00
|
|
|
|
|
|
|
deploy:
|
|
|
|
provider: releases
|
|
|
|
# NOTE updating the `api_key.secure`
|
|
|
|
# - go to: https://github.com/settings/tokens/new
|
|
|
|
# - generate new token using `public_repo` scope
|
2018-12-06 22:18:05 +00:00
|
|
|
# - encrypt it using: `travis encrypt --org API_KEY_HERE`
|
2018-12-06 13:42:16 +00:00
|
|
|
# - paste the output below
|
|
|
|
api_key:
|
2018-12-06 22:21:25 +00:00
|
|
|
secure: "UwCwgVFYe5jALDxZL9d9VQFnCV/1BTpGwwWXS5fOC17OkGD277RIhgMChzJXmHALBJ7o2Jm7ZUxYViEp3/Mk8NlzvMi7sM3wkGaAF0/aAiqsYcxbSyP74j8htjaEDOO99JR9Wp3l74Y52daO4eqlSy3+ZeXIoPVSI9JJlNC1Mhs6bcUvzwCTaCUIU3wc1y9ST4RJizKkSBbtE+OH9CERYZoa1vmDvfAE9BidTu1Fx4kQo0TMpBeFA7+/KAk9BORvGE/97CJ8SdT53oNBozcYluv61pDRcn+Ek6AR7Kh3Z/HJvP6ZWquMygh1G7bVcYZPrSqqB3nTN8t08UZhWMw7QIzqZXd9YuK2WRKVLJaLfbHjm+tkmnaDZpi1OJMMevvdGPuSRTk2rJ/40dAG10sVWd4Ryq9ysLXfsQ2rpqCQdewnrutj9e2X3obO1YDCJzNiONKq+RNiibKWcMf0Rn0B/jFPDdZmPlkJ4M+CVl4mR3vaDMBlPzQkvXmtkWvqkdPn9xrr0CiuItZqEuHcFKtt1mo7MPsgz8FiZ3SzeQ0lYwW5XCsNCEiPWy9l1S/YFNTzpvSyyN3Wtliem5qoCmYVMi3c0mzLGVgTGnO6M1AGme4vD0dptnbov27utWd6sp8PCrxIG4itQxnbTsEYoDQ3EYUBQZX/I3EC0E9fFsmOhzA="
|
2018-12-06 13:42:16 +00:00
|
|
|
# for uploading multiple files
|
|
|
|
file_glob: true
|
|
|
|
# NOTE explanation on each env variable
|
|
|
|
# - PROJECT_NAME: name of the project, set on the `env.global` above
|
|
|
|
# - TRAVIS_TAG: tag name that the build is being deployed for, usually the version number
|
|
|
|
# - TARGET: target triple of the build
|
2018-12-06 22:03:38 +00:00
|
|
|
file:
|
|
|
|
- $PROJECT_NAME-$TRAVIS_TAG-$TARGET.*
|
|
|
|
- $PROJECT_NAME*.deb
|
2018-12-06 13:42:16 +00:00
|
|
|
# don't delete artifacts from previous stage
|
|
|
|
skip_cleanup: true
|
|
|
|
on:
|
|
|
|
# deploy only if we push a tag
|
|
|
|
tags: true
|
|
|
|
# deploy only on stable channel that has TARGET env variable sets
|
|
|
|
condition: $TRAVIS_RUST_VERSION = stable && $TARGET != ""
|
2018-12-06 18:36:05 +00:00
|
|
|
repo: Peltoche/lsd
|
2018-12-06 13:42:16 +00:00
|
|
|
|
|
|
|
notifications:
|
|
|
|
email:
|
|
|
|
on_success: never
|
2018-12-06 18:36:05 +00:00
|
|
|
|
|
|
|
|