diff --git a/tools/azdo_pipelines/run-extractor.yaml b/tools/azdo_pipelines/run-extractor.yaml index 524366b4..bb1e36a4 100644 --- a/tools/azdo_pipelines/run-extractor.yaml +++ b/tools/azdo_pipelines/run-extractor.yaml @@ -94,13 +94,15 @@ stages: Write-Information "Downloading extractor..." $extractorFileName = "extractor.linux-x64" $extractorFinalFileName = "extractor" - if("$(Agent.OS)" -like "*win*"){ + + if ("$(Agent.OS)" -like "*win*") { $extractorFileName = "extractor.win-x64.exe" $extractorFinalFileName = "extractor.exe" } - else if("$(Agent.OS)" -like "*mac*" && "$(Agent.OSArchitecture)" -like "*arm*"){ + elseif ("$(Agent.OS)" -like "*mac*" -and "$(Agent.OSArchitecture)" -like "*arm*") { $extractorFileName = "extractor.osx-arm64" } + $uri = "https://github.com/Azure/apiops/releases/download/$(apiops_release_version)/$extractorFileName" $destinationFilePath = Join-Path "$(Agent.TempDirectory)" $extractorFinalFileName Invoke-WebRequest -Uri "$uri" -OutFile "$destinationFilePath" @@ -276,4 +278,4 @@ stages: Write-Information "Execution complete." pwsh: true env: - AZURE_DEVOPS_EXT_PAT: "$(System.AccessToken)" + AZURE_DEVOPS_EXT_PAT: "$(System.AccessToken)" \ No newline at end of file diff --git a/tools/azdo_pipelines/run-publisher-with-env.yaml b/tools/azdo_pipelines/run-publisher-with-env.yaml index 019cc01f..526e450e 100644 --- a/tools/azdo_pipelines/run-publisher-with-env.yaml +++ b/tools/azdo_pipelines/run-publisher-with-env.yaml @@ -90,11 +90,11 @@ steps: Write-Information "Downloading publisher..." $publisherFileName = "publisher.linux-x64" $publisherFinalFileName = "publisher" - if("$(Agent.OS)" -like "*win*"){ + if ("$(Agent.OS)" -like "*win*") { $publisherFileName = "publisher.win-x64.exe" $publisherFinalFileName = "publisher.exe" } - else if("$(Agent.OS)" -like "*mac*" && "$(Agent.OSArchitecture)" -like "*arm*"){ + elseif ("$(Agent.OS)" -like "*mac*" -and "$(Agent.OSArchitecture)" -like "*arm*") { $publisherFileName = "publisher.osx-arm64" } @@ -143,4 +143,4 @@ steps: ${{ if eq( parameters['COMMIT_ID'], 'publish-artifacts-in-last-commit' ) }}: COMMIT_ID: $(Build.SourceVersion) ${{ if ne( parameters['CONFIGURATION_YAML_PATH'], '' ) }}: - CONFIGURATION_YAML_PATH: ${{ parameters.CONFIGURATION_YAML_PATH }} + CONFIGURATION_YAML_PATH: ${{ parameters.CONFIGURATION_YAML_PATH }} \ No newline at end of file diff --git a/tools/github_workflows/run-extractor.yaml b/tools/github_workflows/run-extractor.yaml index a0f64c60..9bb4fa8e 100644 --- a/tools/github_workflows/run-extractor.yaml +++ b/tools/github_workflows/run-extractor.yaml @@ -50,11 +50,11 @@ jobs: Write-Information "Downloading extractor..." $extractorFileName = "extractor.linux-x64" $extractorFinalFileName = "extractor" - if("${{ runner.os }}" -like "*win*"){ + if ("${{ runner.os }}" -like "*win*") { $extractorFileName = "extractor.win-x64.exe" $extractorFinalFileName = "extractor.exe" } - else if("${{ runner.os }}" -like "*mac*" && "${{ runner.arch }}" -like "*arm*"){ + elseif ("${{ runner.os }}" -like "*mac*" -and "${{ runner.arch }}" -like "*arm*") { $extractorFileName = "extractor.osx-arm64" } diff --git a/tools/github_workflows/run-publisher-with-env.yaml b/tools/github_workflows/run-publisher-with-env.yaml index 622443a4..cef381bb 100644 --- a/tools/github_workflows/run-publisher-with-env.yaml +++ b/tools/github_workflows/run-publisher-with-env.yaml @@ -71,11 +71,11 @@ jobs: Write-Information "Downloading publisher..." $publisherFileName = "publisher.linux-x64" $publisherFinalFileName = "publisher" - if("${{ runner.os }}" -like "*win*"){ + if ("${{ runner.os }}" -like "*win*") { $publisherFileName = "publisher.win-x64.exe" $publisherFinalFileName = "publisher.exe" } - else if("${{ runner.os }}" -like "*mac*" && "${{ runner.arch }}" -like "*arm*"){ + elseif ("${{ runner.os }}" -like "*mac*" -and "${{ runner.arch }}" -like "*arm*") { $publisherFileName = "publisher.osx-arm64" }