mirror of
https://github.com/home-assistant/core.git
synced 2025-07-22 20:57:21 +00:00
Update azure-pipelines.yml for check version (#24194)
This commit is contained in:
parent
1a3a38d370
commit
e7d34913c0
@ -8,7 +8,6 @@ trigger:
|
|||||||
tags:
|
tags:
|
||||||
include:
|
include:
|
||||||
- '*'
|
- '*'
|
||||||
|
|
||||||
variables:
|
variables:
|
||||||
- name: versionBuilder
|
- name: versionBuilder
|
||||||
value: '3.2'
|
value: '3.2'
|
||||||
@ -18,6 +17,7 @@ variables:
|
|||||||
- group: wheels
|
- group: wheels
|
||||||
- group: github
|
- group: github
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
- job: 'Wheels'
|
- job: 'Wheels'
|
||||||
@ -96,8 +96,30 @@ jobs:
|
|||||||
displayName: 'Run wheels build'
|
displayName: 'Run wheels build'
|
||||||
|
|
||||||
|
|
||||||
- job: 'Release'
|
- job: 'VersionValidate'
|
||||||
condition: startsWith(variables['Build.SourceBranch'], 'refs/tags')
|
condition: startsWith(variables['Build.SourceBranch'], 'refs/tags')
|
||||||
|
pool:
|
||||||
|
vmImage: 'ubuntu-latest'
|
||||||
|
steps:
|
||||||
|
- task: UsePythonVersion@0
|
||||||
|
displayName: 'Use Python 3.7'
|
||||||
|
inputs:
|
||||||
|
versionSpec: '3.7'
|
||||||
|
- script: |
|
||||||
|
setup_version="$(python setup.py -V)"
|
||||||
|
branch_version="$(Build.SourceBranchName)"
|
||||||
|
|
||||||
|
if [ "${setup_version}" != "${branch_version}" ]; then
|
||||||
|
echo "Version of tag ${branch_version} don't match with ${setup_version}!"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
displayName: 'Check version of branch/tag'
|
||||||
|
|
||||||
|
|
||||||
|
- job: 'Release'
|
||||||
|
condition: and(startsWith(variables['Build.SourceBranch'], 'refs/tags'), succeeded('VersionValidate')
|
||||||
|
dependsOn:
|
||||||
|
- 'VersionValidate'
|
||||||
timeoutInMinutes: 120
|
timeoutInMinutes: 120
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'ubuntu-16.04'
|
vmImage: 'ubuntu-16.04'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user