From 68bde6422205d1b7aea26258f3b0376ea7120b01 Mon Sep 17 00:00:00 2001 From: MaksimZhukov Date: Wed, 19 Feb 2020 14:30:44 +0300 Subject: [PATCH] Change step to PowerShell task --- images.CI/azure-pipelines/image-generation.yml | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/images.CI/azure-pipelines/image-generation.yml b/images.CI/azure-pipelines/image-generation.yml index 0c05a7e7..477cdc5f 100644 --- a/images.CI/azure-pipelines/image-generation.yml +++ b/images.CI/azure-pipelines/image-generation.yml @@ -6,12 +6,15 @@ jobs: - group: Image Generation Variables steps: - - powershell: | - Remove-Item -path './*' -Recurse -Force - Write-Host "Download $(CUSTOM_REPOSITORY_BRANCH) branch from $(CUSTOM_REPOSITORY_URL)" - git clone $(CUSTOM_REPOSITORY_URL) . -b $(CUSTOM_REPOSITORY_BRANCH) --single-branch --depth 1 + - task: PowerShell@2 displayName: 'Download custom repository' condition: and(ne(variables['CUSTOM_REPOSITORY_BRANCH'], ''), ne(variables['CUSTOM_REPOSITORY_URL'], '')) + inputs: + targetType: 'inline' + script: | + Remove-Item -path './*' -Recurse -Force + Write-Host "Download $(CUSTOM_REPOSITORY_BRANCH) branch from $(CUSTOM_REPOSITORY_URL)" + git clone $(CUSTOM_REPOSITORY_URL) . -b $(CUSTOM_REPOSITORY_BRANCH) --single-branch --depth 1 - task: PowerShell@2 displayName: 'Build VM'