From 83f74df4ca1283fc962b8d7acf0edd9c5316f855 Mon Sep 17 00:00:00 2001 From: Vincent Biret Date: Wed, 18 Aug 2021 09:37:09 -0400 Subject: [PATCH 1/6] - adds a download artifacts stage --- .azure-pipelines/buildAndPackage.yml | 8 +++++--- .azure-pipelines/templates/download-artifacts.yml | 3 +++ 2 files changed, 8 insertions(+), 3 deletions(-) create mode 100644 .azure-pipelines/templates/download-artifacts.yml diff --git a/.azure-pipelines/buildAndPackage.yml b/.azure-pipelines/buildAndPackage.yml index 9def33e71..a19975415 100644 --- a/.azure-pipelines/buildAndPackage.yml +++ b/.azure-pipelines/buildAndPackage.yml @@ -46,7 +46,7 @@ stages: - template: templates/build/publish-artefacts.yml - stage: Maven_Preview - condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/dev')) + # condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/dev')) jobs: - deployment: Maven_Preview environment: 'MSGraph SDK Development - Java' @@ -56,7 +56,8 @@ stages: runOnce: deploy: steps: - - template: templates/install-java.yml + - template: templates/download-artifacts.yml + - template: templates/install-java.yml - template: templates/secure-files.yml - template: templates/copy-and-build.yml parameters: @@ -74,6 +75,7 @@ stages: runOnce: deploy: steps: + - template: templates/download-artifacts.yml - template: templates/install-java.yml - template: templates/secure-files.yml parameters: @@ -91,7 +93,7 @@ stages: runOnce: deploy: steps: - - template: templates/install-java.yml + - template: templates/download-artifacts.yml - template: templates/version-and-release.yml parameters: gitConnection: 'microsoftgraphrelease' diff --git a/.azure-pipelines/templates/download-artifacts.yml b/.azure-pipelines/templates/download-artifacts.yml new file mode 100644 index 000000000..b76d15276 --- /dev/null +++ b/.azure-pipelines/templates/download-artifacts.yml @@ -0,0 +1,3 @@ +steps: + - download: current + artifact: Drop \ No newline at end of file From 3b8348724ca0b8b650c1782851ec7c69a8996fce Mon Sep 17 00:00:00 2001 From: Vincent Biret Date: Wed, 18 Aug 2021 09:48:57 -0400 Subject: [PATCH 2/6] - another path fix attemp --- .azure-pipelines/templates/download-artifacts.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.azure-pipelines/templates/download-artifacts.yml b/.azure-pipelines/templates/download-artifacts.yml index b76d15276..ef0b2a53a 100644 --- a/.azure-pipelines/templates/download-artifacts.yml +++ b/.azure-pipelines/templates/download-artifacts.yml @@ -1,3 +1,6 @@ steps: - - download: current - artifact: Drop \ No newline at end of file + - task: DownloadPipelineArtifact@2 + inputs: + source: current + artifact: Drop + path: '$(Agent.BuildDirectory)/Drop/' \ No newline at end of file From d76266716e23f1574ad93f549d518ac0646906ce Mon Sep 17 00:00:00 2001 From: Vincent Biret Date: Wed, 18 Aug 2021 10:08:18 -0400 Subject: [PATCH 3/6] - updates minimatch pattern for download artifiact task --- .azure-pipelines/templates/download-artifacts.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.azure-pipelines/templates/download-artifacts.yml b/.azure-pipelines/templates/download-artifacts.yml index ef0b2a53a..dfc62df72 100644 --- a/.azure-pipelines/templates/download-artifacts.yml +++ b/.azure-pipelines/templates/download-artifacts.yml @@ -1,6 +1,10 @@ steps: + - download: none - task: DownloadPipelineArtifact@2 inputs: source: current artifact: Drop - path: '$(Agent.BuildDirectory)/Drop/' \ No newline at end of file + path: '$(Agent.BuildDirectory)/Drop/' + patterns: | + ** + * \ No newline at end of file From 66e43709035833a826437a81af9e0f47d62a0637 Mon Sep 17 00:00:00 2001 From: Vincent Biret Date: Wed, 18 Aug 2021 10:18:22 -0400 Subject: [PATCH 4/6] - adds temporary listing task --- .azure-pipelines/templates/download-artifacts.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.azure-pipelines/templates/download-artifacts.yml b/.azure-pipelines/templates/download-artifacts.yml index dfc62df72..53ce4c6e9 100644 --- a/.azure-pipelines/templates/download-artifacts.yml +++ b/.azure-pipelines/templates/download-artifacts.yml @@ -7,4 +7,6 @@ steps: path: '$(Agent.BuildDirectory)/Drop/' patterns: | ** - * \ No newline at end of file + * + - pwsh: Get-ChildItem -Recurse + workingDirectory: $(Agent.BuildDirectory) \ No newline at end of file From e8b55ad4da7313fc0fc6efd9d38399b974c68abf Mon Sep 17 00:00:00 2001 From: Vincent Biret Date: Wed, 18 Aug 2021 10:30:28 -0400 Subject: [PATCH 5/6] - removes painful quote --- .azure-pipelines/templates/copy-and-build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.azure-pipelines/templates/copy-and-build.yml b/.azure-pipelines/templates/copy-and-build.yml index c8ee09cb3..0ae9f5d55 100644 --- a/.azure-pipelines/templates/copy-and-build.yml +++ b/.azure-pipelines/templates/copy-and-build.yml @@ -12,7 +12,7 @@ steps: - task: Gradle@2 inputs: - gradleWrapperFile: $(Agent.BuildDirectory)/Drop/gradlew' + gradleWrapperFile: $(Agent.BuildDirectory)/Drop/gradlew workingDirectory: '$(Agent.BuildDirectory)/Drop/' options: '-x jar -x javadoc -x javadocJar -x compileJava -x processResources -x classes -x sourceJar' tasks: ${{ parameters.task }} From e02c9229f214d6d1e8a6ae55b5ec1baebd2f20ce Mon Sep 17 00:00:00 2001 From: Vincent Biret Date: Wed, 18 Aug 2021 10:41:27 -0400 Subject: [PATCH 6/6] - clean up test sequences from pipeline --- .azure-pipelines/buildAndPackage.yml | 2 +- .azure-pipelines/templates/download-artifacts.yml | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.azure-pipelines/buildAndPackage.yml b/.azure-pipelines/buildAndPackage.yml index a19975415..0092324b9 100644 --- a/.azure-pipelines/buildAndPackage.yml +++ b/.azure-pipelines/buildAndPackage.yml @@ -46,7 +46,7 @@ stages: - template: templates/build/publish-artefacts.yml - stage: Maven_Preview - # condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/dev')) + condition: and(succeeded(), eq(variables['Build.SourceBranch'], 'refs/heads/dev')) jobs: - deployment: Maven_Preview environment: 'MSGraph SDK Development - Java' diff --git a/.azure-pipelines/templates/download-artifacts.yml b/.azure-pipelines/templates/download-artifacts.yml index 53ce4c6e9..dfc62df72 100644 --- a/.azure-pipelines/templates/download-artifacts.yml +++ b/.azure-pipelines/templates/download-artifacts.yml @@ -7,6 +7,4 @@ steps: path: '$(Agent.BuildDirectory)/Drop/' patterns: | ** - * - - pwsh: Get-ChildItem -Recurse - workingDirectory: $(Agent.BuildDirectory) \ No newline at end of file + * \ No newline at end of file