Skip to content

Instantly share code, notes, and snippets.

@dorayakikun
Created March 9, 2019 08:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dorayakikun/e2d26d3e01ff54129fb6edfdad1864eb to your computer and use it in GitHub Desktop.
Save dorayakikun/e2d26d3e01ff54129fb6edfdad1864eb to your computer and use it in GitHub Desktop.
Azure Pipelines使ってみた_rust_example
resources:
containers:
- container: rust
image: rust:latest
jobs:
- job: Linux
pool:
vmImage: 'ubuntu-16.04'
strategy:
matrix:
stable:
rust_toolchain: stable
beta:
rust_toolchain: beta
steps:
- script: |
curl -sSf https://sh.rustup.rs | sh -s -- --default-toolchain $RUST_TOOLCHAIN -y
echo "##vso[task.setvariable variable=PATH;]$PATH:$HOME/.cargo/bin"
$HOME/.cargo/bin/rustup toolchain remove stable && $HOME/.cargo/bin/rustup toolchain add stable
$HOME/.cargo/bin/rustup component add rustfmt
$HOME/.cargo/bin/rustup component add clippy
displayName: Install rustup
- script: cargo fmt --all -- --check
displayName: Run formatter
- script: cargo clippy -- -D warnings
displayName: Run linter
- script: cargo build
displayName: Build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment