diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 0614d88..052b613 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -1,10 +1,14 @@ -name: 0.1.$(rev:r) - trigger: batch: true branches: include: - "*" + paths: + include: + - exporter/* + - azure-pipelines.yml + - requirements.txt + - Dockerfile pr: none @@ -16,6 +20,9 @@ variables: steps: +- task: gittools.gitversion-preview.gitversion-task.GitVersion@5 + displayName: GitVersion + - task: Docker@1 displayName: Build image inputs: @@ -51,3 +58,13 @@ steps: command: Push an image imageName: '$(IMAGE_NAME):latest' +- task: GitHubRelease@0 + displayName: Create a GitHub GitHubRelease + condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/master')) + inputs: + gitHubConnection: 'chelnak' + repositoryName: 'chelnak/status-cake-exporter' + action: 'create' + target: '$(Build.SourceVersion)' + tagSource: 'manual' + tag: '$(Build.BuildNumber)'