From f0e9fb64f3a51ae5c42fedb8e483a413d05f28b3 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Wed, 17 May 2023 20:04:36 -0400 Subject: [PATCH 01/19] add checkout step --- build/azure-pipelines/distro-build.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build/azure-pipelines/distro-build.yml b/build/azure-pipelines/distro-build.yml index db2d245cc530..f10494f22429 100644 --- a/build/azure-pipelines/distro-build.yml +++ b/build/azure-pipelines/distro-build.yml @@ -7,6 +7,9 @@ trigger: pr: none steps: + - checkout: self + persistCredentials: true + - task: NodeTool@0 inputs: versionSpec: "16.x" From bb144129437cd66854d6b87f7a59da05ba6202f1 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Wed, 17 May 2023 23:45:35 -0400 Subject: [PATCH 02/19] update distro build to use System_AccessToken --- build/azure-pipelines/distro-build.yml | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/build/azure-pipelines/distro-build.yml b/build/azure-pipelines/distro-build.yml index f10494f22429..beb3d40df334 100644 --- a/build/azure-pipelines/distro-build.yml +++ b/build/azure-pipelines/distro-build.yml @@ -14,26 +14,10 @@ steps: inputs: versionSpec: "16.x" - - task: AzureKeyVault@1 - displayName: "Azure Key Vault: Get Secrets" - inputs: - azureSubscription: "vscode-builds-subscription" - KeyVaultName: vscode - SecretsFilter: "github-distro-mixin-password" - - script: | set -e - cat << EOF > ~/.netrc - machine github.com - login vscode - password $(github-distro-mixin-password) - EOF - - git config user.email "vscode@microsoft.com" - git config user.name "VSCode" - - git remote add distro "https://github.com/$VSCODE_MIXIN_REPO.git" + git remote add distro "https://$(System_AccessToken)@github.com/$VSCODE_MIXIN_REPO.git" git fetch distro # Push main branch into oss/main @@ -45,3 +29,5 @@ steps: git merge $(node -p "require('./package.json').distro") displayName: Sync & Merge Distro + env: + System_AccessToken: $(System.AccessToken) From cbfb3a357fbc7f8d4f12b66cb4c879fec4326aec Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Thu, 18 May 2023 17:03:01 -0700 Subject: [PATCH 03/19] change to sql-product-compile --- build/azure-pipelines/distro-build.yml | 23 ++++++++++++++----- build/azure-pipelines/sql-product-compile.yml | 22 +++++------------- 2 files changed, 23 insertions(+), 22 deletions(-) diff --git a/build/azure-pipelines/distro-build.yml b/build/azure-pipelines/distro-build.yml index beb3d40df334..db2d245cc530 100644 --- a/build/azure-pipelines/distro-build.yml +++ b/build/azure-pipelines/distro-build.yml @@ -7,17 +7,30 @@ trigger: pr: none steps: - - checkout: self - persistCredentials: true - - task: NodeTool@0 inputs: versionSpec: "16.x" + - task: AzureKeyVault@1 + displayName: "Azure Key Vault: Get Secrets" + inputs: + azureSubscription: "vscode-builds-subscription" + KeyVaultName: vscode + SecretsFilter: "github-distro-mixin-password" + - script: | set -e - git remote add distro "https://$(System_AccessToken)@github.com/$VSCODE_MIXIN_REPO.git" + cat << EOF > ~/.netrc + machine github.com + login vscode + password $(github-distro-mixin-password) + EOF + + git config user.email "vscode@microsoft.com" + git config user.name "VSCode" + + git remote add distro "https://github.com/$VSCODE_MIXIN_REPO.git" git fetch distro # Push main branch into oss/main @@ -29,5 +42,3 @@ steps: git merge $(node -p "require('./package.json').distro") displayName: Sync & Merge Distro - env: - System_AccessToken: $(System.AccessToken) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 31d2f12a5ff6..d0db9c875502 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -1,4 +1,7 @@ steps: +- checkout: self + persistCredentials: true + - task: NodeTool@0 inputs: versionSpec: "16.x" @@ -7,30 +10,17 @@ steps: inputs: versionSpec: "1.x" -- task: AzureKeyVault@1 - displayName: 'Azure Key Vault: Get Secrets' - inputs: - azureSubscription: 'ClientToolsInfra_670062 (88d5392f-a34f-4769-b405-f597fc533613)' - KeyVaultName: ado-secrets - - script: | - set -e - cat << EOF > ~/.netrc - machine github.com - login azuredatastudio - password $(github-distro-mixin-password) - EOF - - git config user.email "sqltools@service.microsoft.com" - git config user.name "AzureDataStudio" displayName: Prepare tooling - script: | set -e - git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git" + git remote add distro "https://$(System_AccessToken)@github.com/$VSCODE_MIXIN_REPO.git" git fetch distro git merge $(node -p "require('./package.json').distro") displayName: Merge distro + env: + System_AccessToken: $(System.AccessToken) - script: | mkdir -p .build From facfb3c4b3b528dae83dadf6cf4de9503f155324 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Fri, 19 May 2023 11:50:23 -0700 Subject: [PATCH 04/19] change formatting for env variable --- build/azure-pipelines/sql-product-compile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index d0db9c875502..48ef05e5e817 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -15,7 +15,7 @@ steps: - script: | set -e - git remote add distro "https://$(System_AccessToken)@github.com/$VSCODE_MIXIN_REPO.git" + git remote add distro "https://$System_AccessToken@github.com/$VSCODE_MIXIN_REPO.git" git fetch distro git merge $(node -p "require('./package.json').distro") displayName: Merge distro From c967f40aa223c46f17462c50f88ae19e9f5669aa Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Fri, 19 May 2023 13:08:49 -0700 Subject: [PATCH 05/19] add extraheader --- build/azure-pipelines/sql-product-compile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 48ef05e5e817..669e6e3d56f3 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -15,7 +15,7 @@ steps: - script: | set -e - git remote add distro "https://$System_AccessToken@github.com/$VSCODE_MIXIN_REPO.git" + git remote add distro "https://github.com/$VSCODE_MIXIN_REPO.git.extraheader AUTHORIZATION: bearer $System.AccessToken" git fetch distro git merge $(node -p "require('./package.json').distro") displayName: Merge distro From ebe2a013446dfc266c685a26c84c9a3af53657c6 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Fri, 19 May 2023 13:55:21 -0700 Subject: [PATCH 06/19] change formatting --- build/azure-pipelines/sql-product-compile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 669e6e3d56f3..167adc714d75 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -15,7 +15,7 @@ steps: - script: | set -e - git remote add distro "https://github.com/$VSCODE_MIXIN_REPO.git.extraheader AUTHORIZATION: bearer $System.AccessToken" + git remote add distro "https://github.com/$VSCODE_MIXIN_REPO.git.extraheader 'AUTHORIZATION: bearer $System.AccessToken'" git fetch distro git merge $(node -p "require('./package.json').distro") displayName: Merge distro From c45049b0b0486f1fb3eccd62f558d4f7c69c91de Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Mon, 22 May 2023 07:47:43 -0700 Subject: [PATCH 07/19] fix formatting --- build/azure-pipelines/sql-product-compile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 167adc714d75..27a181b77ebb 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -15,7 +15,7 @@ steps: - script: | set -e - git remote add distro "https://github.com/$VSCODE_MIXIN_REPO.git.extraheader 'AUTHORIZATION: bearer $System.AccessToken'" + git remote add distro "https://$System.AccessToken@github.com/$VSCODE_MIXIN_REPO.git" git fetch distro git merge $(node -p "require('./package.json').distro") displayName: Merge distro From 3bb13abcd8a01bcb73472e30228e2290c2589e15 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Mon, 22 May 2023 08:11:14 -0700 Subject: [PATCH 08/19] fix env var --- build/azure-pipelines/sql-product-compile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 27a181b77ebb..25141ae2159a 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -15,7 +15,7 @@ steps: - script: | set -e - git remote add distro "https://$System.AccessToken@github.com/$VSCODE_MIXIN_REPO.git" + git remote add distro "https://$(System.AccessToken)@github.com/$VSCODE_MIXIN_REPO.git" git fetch distro git merge $(node -p "require('./package.json').distro") displayName: Merge distro From caffbd0439880d703d94e122dd3b4fb18aaaea8c Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Mon, 22 May 2023 11:28:43 -0700 Subject: [PATCH 09/19] fix format --- build/azure-pipelines/sql-product-compile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 25141ae2159a..fa85eba79c41 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -15,7 +15,7 @@ steps: - script: | set -e - git remote add distro "https://$(System.AccessToken)@github.com/$VSCODE_MIXIN_REPO.git" + git remote add distro "https://$(System.AccessToken)@github.com/$(VSCODE_MIXIN_REPO).git" git fetch distro git merge $(node -p "require('./package.json').distro") displayName: Merge distro From 9d6db7f824519d711ab70efc4471a82c2382c98d Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 14:46:42 -0400 Subject: [PATCH 10/19] checkout repos --- build/azure-pipelines/sql-product-compile.yml | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index fa85eba79c41..e7cd7f37ba7b 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -1,6 +1,20 @@ +resources: + repositories: + - repository: azuredatastudio-release # The name used to reference this repository in the checkout step + type: github + endpoint: CrossPlatBuildScripts + name: microsoft/azuredatastudio-release + - repository: azuredatastudio + type: github + endpoint: CrossPlatBuildScripts + name: microsoft/azuredatastudio + + steps: - checkout: self persistCredentials: true +- checkout: azuredatastudio-release +- checkout: azuredatastudio - task: NodeTool@0 inputs: @@ -15,9 +29,7 @@ steps: - script: | set -e - git remote add distro "https://$(System.AccessToken)@github.com/$(VSCODE_MIXIN_REPO).git" - git fetch distro - git merge $(node -p "require('./package.json').distro") + git merge $(Build.SourcesDirectory)/azuredatastudio-release $(Build.SourcesDirectory)/azuredatastudio displayName: Merge distro env: System_AccessToken: $(System.AccessToken) From 416081d79fe7dc26d69702a3bc4e112fe027f95a Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 15:05:03 -0400 Subject: [PATCH 11/19] remove env var --- build/azure-pipelines/sql-product-compile.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index e7cd7f37ba7b..305894079fe8 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -1,6 +1,6 @@ resources: repositories: - - repository: azuredatastudio-release # The name used to reference this repository in the checkout step + - repository: azuredatastudio-release type: github endpoint: CrossPlatBuildScripts name: microsoft/azuredatastudio-release @@ -31,8 +31,6 @@ steps: set -e git merge $(Build.SourcesDirectory)/azuredatastudio-release $(Build.SourcesDirectory)/azuredatastudio displayName: Merge distro - env: - System_AccessToken: $(System.AccessToken) - script: | mkdir -p .build From 8c7f7a2d7b1f7edd2467bf501797d7e3bf33cf02 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 15:10:00 -0400 Subject: [PATCH 12/19] move location of repositories --- build/azure-pipelines/sql-product-build.yml | 10 ++++++++++ build/azure-pipelines/sql-product-compile.yml | 12 ------------ 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/build/azure-pipelines/sql-product-build.yml b/build/azure-pipelines/sql-product-build.yml index 0ce7c696d8d7..d5524fcaa2fe 100644 --- a/build/azure-pipelines/sql-product-build.yml +++ b/build/azure-pipelines/sql-product-build.yml @@ -4,6 +4,16 @@ resources: image: sqltoolscontainers.azurecr.io/linux-build-agent:6 endpoint: SqlToolsContainers + repositories: + - repository: azuredatastudio-release + type: github + endpoint: CrossPlatBuildScripts + name: microsoft/azuredatastudio-release + - repository: azuredatastudio + type: github + endpoint: CrossPlatBuildScripts + name: microsoft/azuredatastudio + stages: - stage: Compile jobs: diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 305894079fe8..79a74bb6d363 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -1,15 +1,3 @@ -resources: - repositories: - - repository: azuredatastudio-release - type: github - endpoint: CrossPlatBuildScripts - name: microsoft/azuredatastudio-release - - repository: azuredatastudio - type: github - endpoint: CrossPlatBuildScripts - name: microsoft/azuredatastudio - - steps: - checkout: self persistCredentials: true From 92d2489ccfe8348cbf3ffa754543d1ee45a47763 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 15:14:41 -0400 Subject: [PATCH 13/19] print dir of build.sourcesdirectory --- build/azure-pipelines/sql-product-compile.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 79a74bb6d363..e590b7fe1394 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -16,6 +16,7 @@ steps: displayName: Prepare tooling - script: | + dir $(Build.SourcesDirectory) set -e git merge $(Build.SourcesDirectory)/azuredatastudio-release $(Build.SourcesDirectory)/azuredatastudio displayName: Merge distro From d687e30ed7b639a48e9c255d3313bc0c29eea752 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 15:19:24 -0400 Subject: [PATCH 14/19] add git --- build/azure-pipelines/sql-product-compile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index e590b7fe1394..a41304cd7612 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -18,7 +18,7 @@ steps: - script: | dir $(Build.SourcesDirectory) set -e - git merge $(Build.SourcesDirectory)/azuredatastudio-release $(Build.SourcesDirectory)/azuredatastudio + git merge $(Build.SourcesDirectory)/azuredatastudio-release.git $(Build.SourcesDirectory)/azuredatastudio.git displayName: Merge distro - script: | From 09a5333c9cbfe32cd933df69fbe8c9b50c8072f7 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 15:27:25 -0400 Subject: [PATCH 15/19] show inside folders --- build/azure-pipelines/sql-product-compile.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index a41304cd7612..2563843609eb 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -17,6 +17,8 @@ steps: - script: | dir $(Build.SourcesDirectory) + dir $(Build.SourcesDirectory)/azuredatastudio-release + $(Build.SourcesDirectory)/azuredatastudio set -e git merge $(Build.SourcesDirectory)/azuredatastudio-release.git $(Build.SourcesDirectory)/azuredatastudio.git displayName: Merge distro From 1dfe533ddc125f16fb154eb5cafc38e34262d399 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 15:35:05 -0400 Subject: [PATCH 16/19] fix format --- build/azure-pipelines/sql-product-compile.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 2563843609eb..581d666fbde0 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -17,8 +17,10 @@ steps: - script: | dir $(Build.SourcesDirectory) + echo "azuredatastudio-release" dir $(Build.SourcesDirectory)/azuredatastudio-release - $(Build.SourcesDirectory)/azuredatastudio + echo "azuredatastudio" + dir $(Build.SourcesDirectory)/azuredatastudio set -e git merge $(Build.SourcesDirectory)/azuredatastudio-release.git $(Build.SourcesDirectory)/azuredatastudio.git displayName: Merge distro From 131e4944a754b50334cc4262cb4cd6d42f3b293c Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 16:04:00 -0400 Subject: [PATCH 17/19] fix merge command --- build/azure-pipelines/sql-product-compile.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 581d666fbde0..96c04620db3c 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -22,7 +22,8 @@ steps: echo "azuredatastudio" dir $(Build.SourcesDirectory)/azuredatastudio set -e - git merge $(Build.SourcesDirectory)/azuredatastudio-release.git $(Build.SourcesDirectory)/azuredatastudio.git + cd $(Build.SourcesDirectory)/azuredatastudio-release + git merge $(Build.SourcesDirectory)/azuredatastudio displayName: Merge distro - script: | From 7135f1ff730a8bf54e1244a9cb1ead979bbeef33 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 16:13:26 -0400 Subject: [PATCH 18/19] try git merge with distro --- build/azure-pipelines/sql-product-compile.yml | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 96c04620db3c..2f82bea579ed 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -16,14 +16,17 @@ steps: displayName: Prepare tooling - script: | - dir $(Build.SourcesDirectory) - echo "azuredatastudio-release" - dir $(Build.SourcesDirectory)/azuredatastudio-release - echo "azuredatastudio" - dir $(Build.SourcesDirectory)/azuredatastudio + # dir $(Build.SourcesDirectory) + # echo "azuredatastudio-release" + # dir $(Build.SourcesDirectory)/azuredatastudio-release + # echo "azuredatastudio" + # dir $(Build.SourcesDirectory)/azuredatastudio set -e - cd $(Build.SourcesDirectory)/azuredatastudio-release - git merge $(Build.SourcesDirectory)/azuredatastudio + git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git" + git fetch distro + git merge $(node -p "require('./package.json').distro") + # cd $(Build.SourcesDirectory)/azuredatastudio-release + # git merge $(Build.SourcesDirectory)/azuredatastudio displayName: Merge distro - script: | From 03409a3e226d6bc5e02fcf0adcfab11a942e9380 Mon Sep 17 00:00:00 2001 From: Christopher Suh Date: Tue, 23 May 2023 16:29:42 -0400 Subject: [PATCH 19/19] remove test --- build/azure-pipelines/sql-product-compile.yml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/build/azure-pipelines/sql-product-compile.yml b/build/azure-pipelines/sql-product-compile.yml index 2f82bea579ed..13f4851118eb 100644 --- a/build/azure-pipelines/sql-product-compile.yml +++ b/build/azure-pipelines/sql-product-compile.yml @@ -16,17 +16,10 @@ steps: displayName: Prepare tooling - script: | - # dir $(Build.SourcesDirectory) - # echo "azuredatastudio-release" - # dir $(Build.SourcesDirectory)/azuredatastudio-release - # echo "azuredatastudio" - # dir $(Build.SourcesDirectory)/azuredatastudio set -e git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git" git fetch distro git merge $(node -p "require('./package.json').distro") - # cd $(Build.SourcesDirectory)/azuredatastudio-release - # git merge $(Build.SourcesDirectory)/azuredatastudio displayName: Merge distro - script: |