Skip to content

Commit

Permalink
Update azure-pipeline.yml for Azure Pipelines
Browse files Browse the repository at this point in the history
  • Loading branch information
mnelli19 committed Jul 27, 2021
1 parent f864701 commit b6d2eed
Showing 1 changed file with 30 additions and 5 deletions.
35 changes: 30 additions & 5 deletions azure-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ trigger:
- develop
- feature/*
- releases/*
batch: true

pr:
branches:
include:
Expand Down Expand Up @@ -51,7 +51,7 @@ stages:
if [[ ! $GIT_MESSAGE == *"#build"* ]]; then
echo "Not a build commit. Stopping the execution of the build job."
fi
if [[ $GIT_MESSAGE == *"#build-release"* ]]; then
Expand All @@ -69,8 +69,33 @@ stages:
echo '##vso[task.setvariable variable=store]true'
fi
failOnStderr: true
condition: $[eq(variables['Build.Reason'], 'IndividualCI')]

condition: $[ne(variables['Build.Reason'], 'Manual')]
- task: Bash@3
displayName: set PR value
inputs:
targetType: 'inline'
script: |
echo 'Check trigger pipeline var'
echo $(versionCounter)
echo 'commit message: $(Build.SourceVersionMessage)'
echo '##vso[task.setvariable variable=message]$(Build.SourceVersionMessage)'
GIT_MESSAGE=$(Build.SourceVersionMessage)
echo '##vso[task.setvariable variable=build]true'
echo '##vso[task.setvariable variable=debug]true'
if [[ $GIT_MESSAGE == *"#build-release"* ]]; then
echo '##vso[task.setvariable variable=build]true'
echo '##vso[task.setvariable variable=release]true'
fi
if [[ $GIT_MESSAGE == *"#appcenter"* ]]; then
echo '##vso[task.setvariable variable=appcenter]true'
fi
if [[ $GIT_MESSAGE == *"#store"* ]]; then
echo '##vso[task.setvariable variable=store]true'
fi
failOnStderr: true
condition: $[eq(variables['Build.Reason'], 'PullRequest')]
# - task: ExtractVersionFromTag@1
# inputs:
# projectFolderPath: '$(Build.SourcesDirectory)'
Expand All @@ -87,7 +112,7 @@ stages:

- job: BuildApk
dependsOn: InitPipeline
condition: $[eq(variables['build'], true)]
condition: $[succeeded(), eq(variables['build'], true)]
steps:
- checkout: self
clean: true
Expand Down

0 comments on commit b6d2eed

Please sign in to comment.