Skip to content

Commit e686621

Browse files
authored
cli: avoid running prepare a second time in ci (microsoft#184558)
1 parent 9de8137 commit e686621

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

build/azure-pipelines/cli/prepare.js

Lines changed: 2 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

build/azure-pipelines/cli/prepare.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ const makeQualityMap = <T>(m: (productJson: any, quality: string) => T): Record<
3838
*/
3939
const setLauncherEnvironmentVars = () => {
4040
const vars = new Map([
41+
['VSCODE_CLI_ALREADY_PREPARED', 'true'],
4142
['VSCODE_CLI_REMOTE_LICENSE_TEXT', product.serverLicense?.join('\\n')],
4243
['VSCODE_CLI_REMOTE_LICENSE_PROMPT', product.serverLicensePrompt],
4344
['VSCODE_CLI_AI_KEY', product.aiConfig?.cliKey],

cli/build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ fn main() {
2020

2121
fn apply_build_environment_variables() {
2222
// only do this for local, debug builds
23-
if env::var("PROFILE").unwrap() != "debug" {
23+
if env::var("PROFILE").unwrap() != "debug" || env::var("VSCODE_CLI_ALREADY_PREPARED").is_ok() {
2424
return;
2525
}
2626

0 commit comments

Comments
 (0)