From 6d07a311bd7d2bc47297ff8242d109ede95764fe Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Tue, 5 Feb 2019 14:50:33 +0100 Subject: [PATCH] Add CI script for azure pipelines --- azure-pipelines.yml | 51 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 azure-pipelines.yml diff --git a/azure-pipelines.yml b/azure-pipelines.yml new file mode 100644 index 00000000..fa355b07 --- /dev/null +++ b/azure-pipelines.yml @@ -0,0 +1,51 @@ +# Documentation: https://aka.ms/yaml + +trigger: + batch: true + branches: + include: + # This is where pull requests from "bors r+" are built. + - staging + # This is where pull requests from "bors try" are built. + - trying + # Build pull requests. + - master + # Build post braches + - post-* + +strategy: + matrix: + linux: + image_name: 'ubuntu-16.04' + rustup_toolchain: nightly + +pool: + vmImage: $(image_name) + +steps: +- bash: | + echo "Hello world from $AGENT_NAME running on $AGENT_OS" + echo "Reason: $BUILD_REASON" + case "$BUILD_REASON" in + "Manual") echo "$BUILD_REQUESTEDFOR manually queued the build." ;; + "PullRequest") echo "This is a CI build for a pull request on $BUILD_REQUESTEDFOR." ;; + "IndividualCI") echo "This is a CI build for $BUILD_REQUESTEDFOR." ;; + "BatchedCI") echo "This is a batched CI build for $BUILD_REQUESTEDFOR." ;; + *) "$BUILD_REASON" ;; + esac + displayName: 'Build Info' + continueOnError: true + +- script: | + curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain $RUSTUP_TOOLCHAIN + echo "##vso[task.setvariable variable=PATH;]$PATH:$HOME/.cargo/bin" + displayName: 'Install Rust' + +- script: | + rustc -Vv + cargo -V + displayName: 'Print Rust Version' + continueOnError: true + +- script: cargo rustc -- -Z pre-link-arg=-nostartfiles + displayName: 'Build'