summaryrefslogtreecommitdiffstats
path: root/.azure-pipelines.yml
diff options
context:
space:
mode:
authorPietro Albini <pietro@pietroalbini.org>2019-07-12 15:48:53 +0200
committerPietro Albini <pietro@pietroalbini.org>2019-07-13 21:45:20 +0200
commit5bf01b4b591afebc978123e27ab682945fd215a8 (patch)
tree81a7b761f206c42570c69b20c135838abc58e0b9 /.azure-pipelines.yml
parent8578b7e3cdc93b583d5c25762ac36ec512c779f3 (diff)
add the --strict option to the check subcommand
Diffstat (limited to '.azure-pipelines.yml')
-rw-r--r--.azure-pipelines.yml10
1 files changed, 9 insertions, 1 deletions
diff --git a/.azure-pipelines.yml b/.azure-pipelines.yml
index a0ce0fd..d78709d 100644
--- a/.azure-pipelines.yml
+++ b/.azure-pipelines.yml
@@ -20,6 +20,9 @@ steps:
- checkout: self
fetchDepth: 1
+ # Store the GitHub authentication token in the git config. This allows the
+ # next steps to retrieve it.
+ persistCredentials: true
- bash: |
set -e
@@ -29,7 +32,12 @@ steps:
rustc -vV
displayName: Install Rust stable
- - bash: cargo run -- check
+ - bash: |
+ set -euo pipefail
+ # Extract the GitHub authentication token from the git config. The token
+ # will be used to authenticate with the GitHub API.
+ export GITHUB_TOKEN=$(git config -l | grep "\.extraheader=AUTHORIZATION" | awk '{print($3)}' | base64 -d | awk '{split($0,a,":"); print(a[2])}')
+ cargo run -- check --strict
displayName: Validate the repository contents
- bash: cargo fmt -- --check