From 768e9052ddc062f606a6671987ee26d3987521a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Ros?= Date: Mon, 28 Jan 2019 18:02:57 -0800 Subject: [PATCH] Adding artifacts generation for forks (#6324) --- .azure/pipelines/benchmarks.yml | 16 ++++++++++++++++ .azure/pipelines/jobs/default-build.yml | 5 ++++- 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 .azure/pipelines/benchmarks.yml diff --git a/.azure/pipelines/benchmarks.yml b/.azure/pipelines/benchmarks.yml new file mode 100644 index 0000000000..367526a4c7 --- /dev/null +++ b/.azure/pipelines/benchmarks.yml @@ -0,0 +1,16 @@ +# This configuration builds the repository and runs benchmarks + +# Don't run CI for this config +trigger: none + +jobs: +- template: jobs/default-build.yml + parameters: + jobName: Windows_Build + jobDisplayName: "Build only : Windows" + agentOs: Windows + buildArgs: -all -pack + artifacts: + path: artifacts/ + publish: true + force: true diff --git a/.azure/pipelines/jobs/default-build.yml b/.azure/pipelines/jobs/default-build.yml index b328313227..270ff2be8d 100644 --- a/.azure/pipelines/jobs/default-build.yml +++ b/.azure/pipelines/jobs/default-build.yml @@ -21,6 +21,8 @@ # Should artifacts be published # path: string # The file path to artifacts output +# force: boolean +# Should artifacts from forks be published # name: string # The name of the artifact container # variables: { string: string } @@ -56,6 +58,7 @@ parameters: artifacts: publish: true path: 'artifacts/' + force: false buildDirectory: '' buildScript: '' @@ -144,7 +147,7 @@ jobs: - ${{ if eq(parameters.artifacts.publish, 'true') }}: - task: PublishBuildArtifacts@1 displayName: Upload artifacts - condition: eq(variables['system.pullrequest.isfork'], false) + condition: or(eq(variables['system.pullrequest.isfork'], false), eq('${{ parameters.artifacts.force }}', 'true')) continueOnError: true inputs: ${{ if eq(parameters.buildDirectory, '') }}: