Refactor Azure Pipelines config and tweak releases (#244)
* Refactor Azure Pipelines config and tweak releases * Extract out doc/rustfmt jobs into their own separate builders. Helps avoiding having to skip tons of steps and can get failing results more quickly. * Extract out Rust installation logic to a dedicated template. * Separate out the build/test job matrices, where one matrix runs tests and another runs a full build * Refactor release directory structure to follow a convention where `foo.tar.gz` extracts to a folder called `foo` and follow unix-like conventions and copy over the license/readme files into the release tarballs. * Swap order of build/test
This commit is contained in:
committed by
Till Schneidereit
parent
95bcc63ff8
commit
0616062f4f
33
ci/azure-install-rust.yml
Normal file
33
ci/azure-install-rust.yml
Normal file
@@ -0,0 +1,33 @@
|
||||
steps:
|
||||
# Rustup is currently installed on Windows and Linux, but not macOS.
|
||||
# It is installed in /usr/local/cargo/bin/ or C:\Program Files\Rust\.cargo\bin\
|
||||
# This steps ensures that rustup is installed, mainly for macOS, or if the
|
||||
# azure image changes in the future.
|
||||
- bash: |
|
||||
set -ex
|
||||
if [ -x "`command -v rustup`" ]; then
|
||||
echo `command -v rustup` `rustup -V` already installed
|
||||
rustup self update
|
||||
else
|
||||
if [ "$AGENT_OS" = "Windows_NT" ]; then
|
||||
curl -sSf -o rustup-init.exe https://win.rustup.rs
|
||||
./rustup-init.exe -y --default-toolchain $TOOLCHAIN
|
||||
echo "##vso[task.prependpath]$USERPROFILE/.cargo/bin"
|
||||
else
|
||||
curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain $TOOLCHAIN
|
||||
echo "##vso[task.prependpath]$HOME/.cargo/bin"
|
||||
fi
|
||||
fi
|
||||
displayName: Install rustup
|
||||
|
||||
- bash: |
|
||||
set -ex
|
||||
rustup update $TOOLCHAIN
|
||||
rustup default $TOOLCHAIN
|
||||
displayName: Install rust
|
||||
|
||||
- bash: |
|
||||
set -ex
|
||||
rustc -Vv
|
||||
cargo -V
|
||||
displayName: Query rust and cargo versions
|
||||
Reference in New Issue
Block a user