forked from KomodoPlatform/komodo-defi-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines-lint-stage-job.yml
60 lines (58 loc) · 1.79 KB
/
azure-pipelines-lint-stage-job.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# Job template for MM2 Build
parameters:
name: '' # defaults for any parameters that aren't specified
os: ''
bob_passphrase: ''
bob_userpass: ''
alice_passphrase: ''
alice_userpass: ''
telegram_api_key: ''
jobs:
- job: ${{ parameters.name }}
timeoutInMinutes: 0 # 0 means infinite for self-hosted agent
pool:
name: Default
demands: agent.os -equals ${{ parameters.os }}
steps:
- checkout: self # self represents the repo where the initial Pipelines YAML file was found
clean: ${{ eq( variables['Build.Reason'], 'Schedule' ) }} # clean up only on Scheduled build
- bash: |
if [ $CLEANUP = "true" ]
then
git clean -ffdx
fi
displayName: Clean Up
failOnStderr: false
continueOnError: true
- bash: |
cargo fmt -- --check
displayName: 'Check rustfmt warnings'
env:
MANUAL_MM_VERSION: true
- bash: |
if [ $AGENT_OS = "Darwin" ]
then
cargo clippy --profile ci --target x86_64-apple-darwin -- -D warnings
else
cargo clippy --profile ci -- -D warnings
fi
displayName: 'Check Clippy warnings'
env:
MANUAL_MM_VERSION: true
- bash: |
if [ $AGENT_OS = "Darwin" ]
then
cargo check --tests --profile ci --target x86_64-apple-darwin
else
cargo check --tests --profile ci
fi
displayName: 'Check Tests'
env:
MANUAL_MM_VERSION: true
- bash: |
cargo udeps
displayName: 'Check unused dependencies'
- bash: |
cargo deny check bans --hide-inclusion-graph
cargo deny check advisories --hide-inclusion-graph
displayName: 'Cargo deny checks'