mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-24 11:01:38 -05:00
Compare commits
27 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
13e3627627 | ||
|
|
e2111fe493 | ||
|
|
7b46269b44 | ||
|
|
69b9a19634 | ||
|
|
ebe835ec99 | ||
|
|
d4e25f4d89 | ||
|
|
809d4de862 | ||
|
|
e1aae951a3 | ||
|
|
bdd99bd0d8 | ||
|
|
c06bfad916 | ||
|
|
1c91f7971e | ||
|
|
8c9037fbdf | ||
|
|
d029bb9602 | ||
|
|
f0558714a4 | ||
|
|
49147305e8 | ||
|
|
519012c690 | ||
|
|
ff05bc2b03 | ||
|
|
b54beb6e7a | ||
|
|
dbdcc3d20a | ||
|
|
cf48776710 | ||
|
|
309f750b92 | ||
|
|
8c92af3016 | ||
|
|
9b117da9cb | ||
|
|
d12a7b81fd | ||
|
|
3eb705e77b | ||
|
|
b421b19b73 | ||
|
|
124f7ca887 |
@@ -14,4 +14,3 @@
|
|||||||
**/extensions/**/build/**
|
**/extensions/**/build/**
|
||||||
**/extensions/markdown-language-features/media/**
|
**/extensions/markdown-language-features/media/**
|
||||||
**/extensions/typescript-basics/test/colorize-fixtures/**
|
**/extensions/typescript-basics/test/colorize-fixtures/**
|
||||||
**/extensions/**/dist/**
|
|
||||||
|
|||||||
@@ -740,8 +740,6 @@
|
|||||||
"angular2-grid",
|
"angular2-grid",
|
||||||
"html-query-plan",
|
"html-query-plan",
|
||||||
"turndown",
|
"turndown",
|
||||||
"gridstack",
|
|
||||||
"gridstack/**",
|
|
||||||
"mark.js",
|
"mark.js",
|
||||||
"vscode-textmate",
|
"vscode-textmate",
|
||||||
"vscode-oniguruma",
|
"vscode-oniguruma",
|
||||||
@@ -941,13 +939,6 @@
|
|||||||
"*" // node modules
|
"*" // node modules
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"target": "**/test/monaco/**",
|
|
||||||
"restrictions": [
|
|
||||||
"**/test/monaco/**",
|
|
||||||
"*" // node modules
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"target": "**/api/**.test.ts",
|
"target": "**/api/**.test.ts",
|
||||||
"restrictions": [
|
"restrictions": [
|
||||||
@@ -955,9 +946,9 @@
|
|||||||
"assert",
|
"assert",
|
||||||
"sinon",
|
"sinon",
|
||||||
"crypto",
|
"crypto",
|
||||||
"vscode",
|
"vscode",
|
||||||
"typemoq",
|
"typemoq",
|
||||||
"azdata"
|
"azdata"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
5
.github/copycat.yml
vendored
Normal file
5
.github/copycat.yml
vendored
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
{
|
||||||
|
perform: false,
|
||||||
|
target_owner: 'anthonydresser',
|
||||||
|
target_repo: 'testissues'
|
||||||
|
}
|
||||||
35
.github/workflows/build-chat.yml
vendored
35
.github/workflows/build-chat.yml
vendored
@@ -1,35 +0,0 @@
|
|||||||
name: "Build Chat"
|
|
||||||
|
|
||||||
on:
|
|
||||||
workflow_run:
|
|
||||||
workflows:
|
|
||||||
- CI
|
|
||||||
types:
|
|
||||||
- completed
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
- release/*
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
main:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout Actions
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
with:
|
|
||||||
repository: "microsoft/vscode-github-triage-actions"
|
|
||||||
path: ./actions
|
|
||||||
- name: Install Actions
|
|
||||||
run: npm install --production --prefix ./actions
|
|
||||||
- name: Install Additional Dependencies
|
|
||||||
# Pulls in a bunch of other packages that arent needed for the rest of the actions
|
|
||||||
run: npm install @azure/storage-blob@12.1.1
|
|
||||||
- name: Build Chat
|
|
||||||
uses: ./actions/build-chat
|
|
||||||
with:
|
|
||||||
token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
slack_token: ${{ secrets.SLACK_TOKEN }}
|
|
||||||
storage_connection_string: ${{ secrets.BUILD_CHAT_STORAGE_CONNECTION_STRING }}
|
|
||||||
workflow_run_url: ${{ github.event.workflow_run.url }}
|
|
||||||
notification_channel: build
|
|
||||||
log_channel: bot-log
|
|
||||||
2
.github/workflows/deep-classifier-runner.yml
vendored
2
.github/workflows/deep-classifier-runner.yml
vendored
@@ -13,7 +13,7 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
repository: "microsoft/vscode-github-triage-actions"
|
repository: "microsoft/vscode-github-triage-actions"
|
||||||
ref: v42
|
ref: v40
|
||||||
path: ./actions
|
path: ./actions
|
||||||
- name: Install Actions
|
- name: Install Actions
|
||||||
run: npm install --production --prefix ./actions
|
run: npm install --production --prefix ./actions
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ jobs:
|
|||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
repository: "microsoft/vscode-github-triage-actions"
|
repository: "microsoft/vscode-github-triage-actions"
|
||||||
ref: v42
|
ref: v40
|
||||||
path: ./actions
|
path: ./actions
|
||||||
- name: Install Actions
|
- name: Install Actions
|
||||||
run: npm install --production --prefix ./actions
|
run: npm install --production --prefix ./actions
|
||||||
|
|||||||
2
.github/workflows/latest-release-monitor.yml
vendored
2
.github/workflows/latest-release-monitor.yml
vendored
@@ -14,7 +14,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
repository: "microsoft/vscode-github-triage-actions"
|
repository: "microsoft/vscode-github-triage-actions"
|
||||||
path: ./actions
|
path: ./actions
|
||||||
ref: v42
|
ref: v40
|
||||||
- name: Install Actions
|
- name: Install Actions
|
||||||
run: npm install --production --prefix ./actions
|
run: npm install --production --prefix ./actions
|
||||||
- name: Install Storage Module
|
- name: Install Storage Module
|
||||||
|
|||||||
24
.github/workflows/on-issue-open.yml
vendored
Normal file
24
.github/workflows/on-issue-open.yml
vendored
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
name: On Issue Open
|
||||||
|
on:
|
||||||
|
issues:
|
||||||
|
types: [opened]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
main:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout Actions
|
||||||
|
uses: actions/checkout@v2.2.0
|
||||||
|
with:
|
||||||
|
repository: 'microsoft/azuredatastudio'
|
||||||
|
ref: main
|
||||||
|
path: ./actions
|
||||||
|
- name: Install Actions
|
||||||
|
run: npm install --production --prefix ./actions/build/actions
|
||||||
|
|
||||||
|
- name: Run CopyCat
|
||||||
|
uses: ./actions/build/actions/copycat
|
||||||
|
with:
|
||||||
|
token: ${{secrets.TRIAGE_PAT}}
|
||||||
|
owner: anthonydresser
|
||||||
|
repo: testissues
|
||||||
22
.gitignore
vendored
22
.gitignore
vendored
@@ -5,8 +5,26 @@ Thumbs.db
|
|||||||
node_modules/
|
node_modules/
|
||||||
.build/
|
.build/
|
||||||
extensions/**/dist/
|
extensions/**/dist/
|
||||||
/out*/
|
out/
|
||||||
/extensions/**/out/
|
out-build/
|
||||||
|
out-editor/
|
||||||
|
out-editor-src/
|
||||||
|
out-editor-build/
|
||||||
|
out-editor-esm/
|
||||||
|
out-editor-esm-bundle/
|
||||||
|
out-editor-min/
|
||||||
|
out-monaco-editor-core/
|
||||||
|
out-vscode/
|
||||||
|
out-vscode-min/
|
||||||
|
out-vscode-reh/
|
||||||
|
out-vscode-reh-min/
|
||||||
|
out-vscode-reh-pkg/
|
||||||
|
out-vscode-reh-web/
|
||||||
|
out-vscode-reh-web-min/
|
||||||
|
out-vscode-reh-web-pkg/
|
||||||
|
out-vscode-web/
|
||||||
|
out-vscode-web-min/
|
||||||
|
out-vscode-web-pkg/
|
||||||
src/vs/server
|
src/vs/server
|
||||||
resources/server
|
resources/server
|
||||||
build/node_modules
|
build/node_modules
|
||||||
|
|||||||
3
.vscode/extensions.json
vendored
3
.vscode/extensions.json
vendored
@@ -3,6 +3,7 @@
|
|||||||
// for the documentation about the extensions.json format
|
// for the documentation about the extensions.json format
|
||||||
"recommendations": [
|
"recommendations": [
|
||||||
"dbaeumer.vscode-eslint",
|
"dbaeumer.vscode-eslint",
|
||||||
"EditorConfig.EditorConfig"
|
"EditorConfig.EditorConfig",
|
||||||
|
"msjsdiag.debugger-for-chrome"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
19
.vscode/launch.json
vendored
19
.vscode/launch.json
vendored
@@ -105,7 +105,8 @@
|
|||||||
"outFiles": [
|
"outFiles": [
|
||||||
"${workspaceFolder}/out/**/*.js"
|
"${workspaceFolder}/out/**/*.js"
|
||||||
],
|
],
|
||||||
"browserLaunchLocation": "workspace"
|
"browserLaunchLocation": "workspace",
|
||||||
|
"preLaunchTask": "Ensure Prelaunch Dependencies",
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "node",
|
"type": "node",
|
||||||
@@ -140,6 +141,7 @@
|
|||||||
"type": "pwa-chrome",
|
"type": "pwa-chrome",
|
||||||
"request": "launch",
|
"request": "launch",
|
||||||
"outFiles": [],
|
"outFiles": [],
|
||||||
|
"outFiles": [],
|
||||||
"perScriptSourcemaps": "yes",
|
"perScriptSourcemaps": "yes",
|
||||||
"name": "VS Code (Web, Chrome)",
|
"name": "VS Code (Web, Chrome)",
|
||||||
"url": "http://localhost:8080",
|
"url": "http://localhost:8080",
|
||||||
@@ -213,7 +215,7 @@
|
|||||||
"${workspaceFolder}/out/**/*.js"
|
"${workspaceFolder}/out/**/*.js"
|
||||||
],
|
],
|
||||||
"cascadeTerminateToConfigurations": [
|
"cascadeTerminateToConfigurations": [
|
||||||
"Attach to azuredatastudio"
|
"Attach to VS Code"
|
||||||
],
|
],
|
||||||
"env": {
|
"env": {
|
||||||
"MOCHA_COLORS": "true"
|
"MOCHA_COLORS": "true"
|
||||||
@@ -227,15 +229,15 @@
|
|||||||
"request": "launch",
|
"request": "launch",
|
||||||
"name": "Run Unit Tests For Current File",
|
"name": "Run Unit Tests For Current File",
|
||||||
"program": "${workspaceFolder}/test/unit/electron/index.js",
|
"program": "${workspaceFolder}/test/unit/electron/index.js",
|
||||||
"runtimeExecutable": "${workspaceFolder}/.build/electron/Azure Data Studio.app/Contents/MacOS/Electron",
|
"runtimeExecutable": "${workspaceFolder}/.build/electron/Code - OSS.app/Contents/MacOS/Electron",
|
||||||
"windows": {
|
"windows": {
|
||||||
"runtimeExecutable": "${workspaceFolder}/.build/electron/azuredatastudio.exe"
|
"runtimeExecutable": "${workspaceFolder}/.build/electron/Code - OSS.exe"
|
||||||
},
|
},
|
||||||
"linux": {
|
"linux": {
|
||||||
"runtimeExecutable": "${workspaceFolder}/.build/electron/azuredatastudio"
|
"runtimeExecutable": "${workspaceFolder}/.build/electron/code-oss"
|
||||||
},
|
},
|
||||||
"cascadeTerminateToConfigurations": [
|
"cascadeTerminateToConfigurations": [
|
||||||
"Attach to azuredatastudio"
|
"Attach to VS Code"
|
||||||
],
|
],
|
||||||
"outputCapture": "std",
|
"outputCapture": "std",
|
||||||
"args": [
|
"args": [
|
||||||
@@ -249,6 +251,9 @@
|
|||||||
],
|
],
|
||||||
"env": {
|
"env": {
|
||||||
"MOCHA_COLORS": "true"
|
"MOCHA_COLORS": "true"
|
||||||
|
},
|
||||||
|
"presentation": {
|
||||||
|
"hidden": true
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -351,7 +356,7 @@
|
|||||||
{
|
{
|
||||||
"name": "Debug Unit Tests (Current File)",
|
"name": "Debug Unit Tests (Current File)",
|
||||||
"configurations": [
|
"configurations": [
|
||||||
"Attach to azuredatastudio",
|
"Attach to VS Code",
|
||||||
"Run Unit Tests For Current File"
|
"Run Unit Tests For Current File"
|
||||||
],
|
],
|
||||||
"presentation": {
|
"presentation": {
|
||||||
|
|||||||
2
.vscode/notebooks/api.github-issues
vendored
2
.vscode/notebooks/api.github-issues
vendored
@@ -8,7 +8,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$repo=repo:microsoft/vscode\n$milestone=milestone:\"February 2021\"",
|
"value": "$repo=repo:microsoft/vscode\n$milestone=milestone:\"November 2020\"",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
28
.vscode/notebooks/endgame.github-issues
vendored
28
.vscode/notebooks/endgame.github-issues
vendored
@@ -8,8 +8,8 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server repo:microsoft/vscode-emmet-helper\n\n$MILESTONE=milestone:\"January 2021\"",
|
"value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server\n\n$MILESTONE=milestone:\"November 2020\"",
|
||||||
"editable": true
|
"editable": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": 1,
|
"kind": 1,
|
||||||
@@ -80,7 +80,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE is:issue is:closed label:feature-request label:verification-needed -label:verified",
|
"value": "$REPOS $MILESTONE is:issue is:closed label:feature-request label:verification-needed",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -89,28 +89,10 @@
|
|||||||
"value": "# Verification",
|
"value": "# Verification",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "## Verifiable Fixes",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE is:issue is:closed sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found -label:z-author-verified -label:unreleased",
|
"value": "$REPOS $MILESTONE is:issue is:closed sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found",
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "## Unreleased Fixes",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 2,
|
|
||||||
"language": "github-issues",
|
|
||||||
"value": "$REPOS $MILESTONE is:issue is:closed sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found -label:z-author-verified label:unreleased",
|
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -122,7 +104,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE is:open label:candidate",
|
"value": "$REPOS $MILESTONE label:candidate",
|
||||||
"editable": true
|
"editable": true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
@@ -176,20 +176,17 @@
|
|||||||
{
|
{
|
||||||
"kind": 1,
|
"kind": 1,
|
||||||
"language": "markdown",
|
"language": "markdown",
|
||||||
"value": "# vscode-pull-request-github",
|
"value": "# vscode-pull-request-github"
|
||||||
"editable": true
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "repo:microsoft/vscode-pull-request-github is:issue closed:>$since",
|
"value": "repo:microsoft/vscode-pull-request-github is:issue closed:>$since"
|
||||||
"editable": true
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "repo:microsoft/vscode-test is:issue created:>$since",
|
"value": "repo:microsoft/vscode-test is:issue created:>$since"
|
||||||
"editable": true
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": 1,
|
"kind": 1,
|
||||||
|
|||||||
26
.vscode/notebooks/my-endgame.github-issues
vendored
26
.vscode/notebooks/my-endgame.github-issues
vendored
@@ -8,8 +8,8 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server\n\n$MILESTONE=milestone:\"January 2021\"\n\n$MINE=assignee:@me",
|
"value": "$REPOS=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-js-debug repo:microsoft/vscode-remote-release repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-settings-sync-server\n\n$MILESTONE=milestone:\"November 2020\"\n\n$MINE=assignee:@me",
|
||||||
"editable": true
|
"editable": false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": 1,
|
"kind": 1,
|
||||||
@@ -122,7 +122,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE $MINE is:issue is:open -label:endgame-plan",
|
"value": "$REPOS $MILESTONE $MINE is:issue is:open",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -152,7 +152,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE $MINE is:issue label:bug label:verification-steps-needed",
|
"value": "$REPOS $MILESTONE $MINE is:issue is:open label:bug label:verification-steps-needed",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -164,7 +164,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE $MINE is:issue label:bug label:verification-found",
|
"value": "$REPOS $MILESTONE $MINE is:issue is:open label:bug label:verification-found",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -176,19 +176,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE -$MINE is:issue is:closed author:@me sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found",
|
"value": "$REPOS $MILESTONE -$MINE is:issue is:closed author:@me sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found",
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "## Issues filed from outside team",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 2,
|
|
||||||
"language": "github-issues",
|
|
||||||
"value": "$REPOS $MILESTONE -$MINE is:issue is:closed sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found -author:aeschli -author:alexdima -author:alexr00 -author:AmandaSilver -author:bamurtaugh -author:bpasero -author:btholt -author:chrisdias -author:chrmarti -author:Chuxel -author:connor4312 -author:dbaeumer -author:deepak1556 -author:devinvalenciano -author:digitarald -author:eamodio -author:egamma -author:fiveisprime -author:gregvanl -author:isidorn -author:ItalyPaleAle -author:JacksonKearl -author:joaomoreno -author:jrieken -author:kieferrm -author:lszomoru -author:meganrogge -author:misolori -author:mjbvz -author:ornellaalt -author:orta -author:rebornix -author:RMacfarlane -author:roblourens -author:rzhao271 -author:sana-ajani -author:sandy081 -author:sbatten -author:stevencl -author:Tyriar -author:weinand -author:TylerLeonhardt -author:lramos15",
|
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -200,7 +188,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$REPOS $MILESTONE -$MINE is:issue is:closed -author:@me sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found",
|
"value": "$REPOS $MILESTONE -$MINE is:issue is:closed -author:@me sort:updated-asc label:bug -label:verified -label:on-testplan -label:*duplicate -label:invalid -label:*as-designed -label:error-telemetry -label:verification-steps-needed -label:verification-found",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
20
.vscode/notebooks/my-work.github-issues
vendored
20
.vscode/notebooks/my-work.github-issues
vendored
@@ -8,7 +8,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "// list of repos we work in\n$repos=repo:microsoft/vscode repo:microsoft/vscode-remote-release repo:microsoft/vscode-js-debug repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-github-issue-notebooks repo:microsoft/vscode-internalbacklog\n\n// current milestone name\n$milestone=milestone:\"February 2021\"",
|
"value": "// list of repos we work in\n$repos=repo:microsoft/vscode repo:microsoft/vscode-remote-release repo:microsoft/vscode-js-debug repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-github-issue-notebooks repo:microsoft/vscode-internalbacklog\n\n// current milestone name\n$milestone=milestone:\"November 2020\"",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -83,24 +83,6 @@
|
|||||||
"value": "$repos assignee:@me is:open milestone:\"Backlog Candidates\"",
|
"value": "$repos assignee:@me is:open milestone:\"Backlog Candidates\"",
|
||||||
"editable": false
|
"editable": false
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "### Personal Inbox\n",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "\n#### Missing Type label",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 2,
|
|
||||||
"language": "github-issues",
|
|
||||||
"value": "$repos assignee:@me is:open type:issue -label:bug -label:\"needs more info\" -label:feature-request -label:under-discussion -label:debt -label:plan-item -label:upstream",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"kind": 1,
|
"kind": 1,
|
||||||
"language": "markdown",
|
"language": "markdown",
|
||||||
|
|||||||
44
.vscode/notebooks/papercuts.github-issues
vendored
44
.vscode/notebooks/papercuts.github-issues
vendored
@@ -1,44 +0,0 @@
|
|||||||
[
|
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "## Papercuts\n\nThis notebook serves as an ongoing collection of papercut issues that we encounter while dogfooding. With that in mind only promote issues that really turn you off, e.g. issues that make you want to stop using VS Code or its extensions. To mark an issue (bug, feature-request, etc.) as papercut add the labels: `papercut :drop_of_blood:`",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "## All Papercuts\n\nThese are all papercut issues that we encounter while dogfooding vscode or extensions that we author.",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 2,
|
|
||||||
"language": "github-issues",
|
|
||||||
"value": "repo:microsoft/vscode is:open -label:notebook label:\"papercut :drop_of_blood:\"",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "## Native Notebook",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 2,
|
|
||||||
"language": "github-issues",
|
|
||||||
"value": "repo:microsoft/vscode is:open label:notebook label:\"papercut :drop_of_blood:\"",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 1,
|
|
||||||
"language": "markdown",
|
|
||||||
"value": "### My Papercuts",
|
|
||||||
"editable": true
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"kind": 2,
|
|
||||||
"language": "github-issues",
|
|
||||||
"value": "repo:microsoft/vscode is:open assignee:@me label:\"papercut :drop_of_blood:\"",
|
|
||||||
"editable": true
|
|
||||||
}
|
|
||||||
]
|
|
||||||
2
.vscode/notebooks/verification.github-issues
vendored
2
.vscode/notebooks/verification.github-issues
vendored
@@ -14,7 +14,7 @@
|
|||||||
{
|
{
|
||||||
"kind": 2,
|
"kind": 2,
|
||||||
"language": "github-issues",
|
"language": "github-issues",
|
||||||
"value": "$repos=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-remote-release repo:microsoft/vscode-js-debug repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-github-issue-notebooks \n$milestone=milestone:\"January 2021\"",
|
"value": "$repos=repo:microsoft/vscode repo:microsoft/vscode-internalbacklog repo:microsoft/vscode-remote-release repo:microsoft/vscode-js-debug repo:microsoft/vscode-pull-request-github repo:microsoft/vscode-github-issue-notebooks \n$milestone=milestone:\"October 2020\"",
|
||||||
"editable": true
|
"editable": true
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
8
.vscode/tasks.json
vendored
8
.vscode/tasks.json
vendored
@@ -62,8 +62,7 @@
|
|||||||
"group": {
|
"group": {
|
||||||
"kind": "build",
|
"kind": "build",
|
||||||
"isDefault": true
|
"isDefault": true
|
||||||
},
|
}
|
||||||
"problemMatcher": []
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "npm",
|
"type": "npm",
|
||||||
@@ -91,8 +90,7 @@
|
|||||||
"Kill Build VS Code Core",
|
"Kill Build VS Code Core",
|
||||||
"Kill Build VS Code Extensions"
|
"Kill Build VS Code Extensions"
|
||||||
],
|
],
|
||||||
"group": "build",
|
"group": "build"
|
||||||
"problemMatcher": []
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"type": "npm",
|
"type": "npm",
|
||||||
@@ -219,7 +217,7 @@
|
|||||||
"base": "$tsc",
|
"base": "$tsc",
|
||||||
"applyTo": "allDocuments",
|
"applyTo": "allDocuments",
|
||||||
"owner": "tsec"
|
"owner": "tsec"
|
||||||
}
|
},
|
||||||
],
|
],
|
||||||
"group": "build",
|
"group": "build",
|
||||||
"label": "npm: tsec-compile-check",
|
"label": "npm: tsec-compile-check",
|
||||||
|
|||||||
2
.yarnrc
2
.yarnrc
@@ -1,3 +1,3 @@
|
|||||||
disturl "https://electronjs.org/headers"
|
disturl "https://electronjs.org/headers"
|
||||||
target "11.2.2"
|
target "9.4.3"
|
||||||
runtime "electron"
|
runtime "electron"
|
||||||
|
|||||||
22
CHANGELOG.md
22
CHANGELOG.md
@@ -1,25 +1,5 @@
|
|||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
## Version 1.29.0
|
|
||||||
* Release date: May 19, 2021
|
|
||||||
* Release status: General Availability
|
|
||||||
* New Notebook Features:
|
|
||||||
* Added runs with a parameters option.
|
|
||||||
* Extension Updates:
|
|
||||||
* SQL Database Projects
|
|
||||||
* Schema Compare
|
|
||||||
* Bug Fixes
|
|
||||||
|
|
||||||
## Version 1.28.0
|
|
||||||
* Release date: April 16, 2021
|
|
||||||
* Release status: General Availability
|
|
||||||
* New Notebook Features:
|
|
||||||
* Added Add Notebook and Remove Notebook commands
|
|
||||||
* Extension Updates:
|
|
||||||
* SQL Database Projects
|
|
||||||
* Schema Compare
|
|
||||||
* Bug Fixes
|
|
||||||
|
|
||||||
## Version 1.27.0
|
## Version 1.27.0
|
||||||
* Release date: March 17, 2021
|
* Release date: March 17, 2021
|
||||||
* Release status: General Availability
|
* Release status: General Availability
|
||||||
@@ -33,7 +13,7 @@
|
|||||||
* Arc
|
* Arc
|
||||||
* SQL Database Projects
|
* SQL Database Projects
|
||||||
* ASDE Deployment
|
* ASDE Deployment
|
||||||
* Bug Fixes
|
* Bux Fixes
|
||||||
|
|
||||||
## Version 1.26.1
|
## Version 1.26.1
|
||||||
* Release date: February 25, 2021
|
* Release date: February 25, 2021
|
||||||
|
|||||||
14
README.md
14
README.md
@@ -131,10 +131,10 @@ Copyright (c) Microsoft Corporation. All rights reserved.
|
|||||||
|
|
||||||
Licensed under the [Source EULA](LICENSE.txt).
|
Licensed under the [Source EULA](LICENSE.txt).
|
||||||
|
|
||||||
[win-user]: https://go.microsoft.com/fwlink/?linkid=2163435
|
[win-user]: https://go.microsoft.com/fwlink/?linkid=2157460
|
||||||
[win-system]: https://go.microsoft.com/fwlink/?linkid=2163531
|
[win-system]: https://go.microsoft.com/fwlink/?linkid=2157459
|
||||||
[win-zip]: https://go.microsoft.com/fwlink/?linkid=2163529
|
[win-zip]: https://go.microsoft.com/fwlink/?linkid=2157458
|
||||||
[osx-zip]: https://go.microsoft.com/fwlink/?linkid=2163528
|
[osx-zip]: https://go.microsoft.com/fwlink/?linkid=2157456
|
||||||
[linux-zip]: https://go.microsoft.com/fwlink/?linkid=2163530
|
[linux-zip]: https://go.microsoft.com/fwlink/?linkid=2157353
|
||||||
[linux-rpm]: https://go.microsoft.com/fwlink/?linkid=2163437
|
[linux-rpm]: https://go.microsoft.com/fwlink/?linkid=2157248
|
||||||
[linux-deb]: https://go.microsoft.com/fwlink/?linkid=2163436
|
[linux-deb]: https://go.microsoft.com/fwlink/?linkid=2157352
|
||||||
|
|||||||
@@ -29,7 +29,6 @@ expressly granted herein, whether by implication, estoppel or otherwise.
|
|||||||
gc-signals: https://github.com/Microsoft/node-gc-signals
|
gc-signals: https://github.com/Microsoft/node-gc-signals
|
||||||
getmac: https://github.com/bevry/getmac
|
getmac: https://github.com/bevry/getmac
|
||||||
graceful-fs: https://github.com/isaacs/node-graceful-fs
|
graceful-fs: https://github.com/isaacs/node-graceful-fs
|
||||||
gridstack: https://github.com/gridstack/gridstack.js
|
|
||||||
html-query-plan: https://github.com/JustinPealing/html-query-plan
|
html-query-plan: https://github.com/JustinPealing/html-query-plan
|
||||||
http-proxy-agent: https://github.com/TooTallNate/node-https-proxy-agent
|
http-proxy-agent: https://github.com/TooTallNate/node-https-proxy-agent
|
||||||
https-proxy-agent: https://github.com/TooTallNate/node-https-proxy-agent
|
https-proxy-agent: https://github.com/TooTallNate/node-https-proxy-agent
|
||||||
@@ -494,32 +493,6 @@ IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|||||||
=========================================
|
=========================================
|
||||||
END OF graceful-fs NOTICES AND INFORMATION
|
END OF graceful-fs NOTICES AND INFORMATION
|
||||||
|
|
||||||
%% gridstack NOTICES AND INFORMATION BEGIN HERE
|
|
||||||
=========================================
|
|
||||||
The MIT License (MIT)
|
|
||||||
|
|
||||||
Copyright (c) 2014-2020 Alain Dumesny, Dylan Weiss, Pavel Reznikov
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
|
||||||
in the Software without restriction, including without limitation the rights
|
|
||||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all
|
|
||||||
copies or substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
||||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
||||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
||||||
SOFTWARE.
|
|
||||||
=========================================
|
|
||||||
END OF gridstack NOTICES AND INFORMATION
|
|
||||||
|
|
||||||
%% html-query-plan NOTICES AND INFORMATION BEGIN HERE
|
%% html-query-plan NOTICES AND INFORMATION BEGIN HERE
|
||||||
=========================================
|
=========================================
|
||||||
The MIT License (MIT)
|
The MIT License (MIT)
|
||||||
|
|||||||
@@ -20,8 +20,3 @@ jobs:
|
|||||||
vmImage: macOS-latest
|
vmImage: macOS-latest
|
||||||
steps:
|
steps:
|
||||||
- template: build/azure-pipelines/darwin/continuous-build-darwin.yml
|
- template: build/azure-pipelines/darwin/continuous-build-darwin.yml
|
||||||
|
|
||||||
trigger:
|
|
||||||
branches:
|
|
||||||
exclude:
|
|
||||||
- electron-11.x.y
|
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
2021-04-07T00:04:17.775Z
|
2020-04-29T05:20:58.491Z
|
||||||
|
|||||||
@@ -1,6 +1,4 @@
|
|||||||
# cleanup rules for node modules, .gitignore style
|
# cleanup rules for native node modules, .gitignore style
|
||||||
|
|
||||||
# native node modules
|
|
||||||
|
|
||||||
nan/**
|
nan/**
|
||||||
*/node_modules/nan/**
|
*/node_modules/nan/**
|
||||||
@@ -48,7 +46,6 @@ spdlog/build/**
|
|||||||
spdlog/deps/**
|
spdlog/deps/**
|
||||||
spdlog/src/**
|
spdlog/src/**
|
||||||
spdlog/test/**
|
spdlog/test/**
|
||||||
spdlog/*.yml
|
|
||||||
!spdlog/build/Release/*.node
|
!spdlog/build/Release/*.node
|
||||||
|
|
||||||
jschardet/dist/**
|
jschardet/dist/**
|
||||||
@@ -75,7 +72,6 @@ node-pty/build/**
|
|||||||
node-pty/src/**
|
node-pty/src/**
|
||||||
node-pty/tools/**
|
node-pty/tools/**
|
||||||
node-pty/deps/**
|
node-pty/deps/**
|
||||||
node-pty/scripts/**
|
|
||||||
!node-pty/build/Release/*.exe
|
!node-pty/build/Release/*.exe
|
||||||
!node-pty/build/Release/*.dll
|
!node-pty/build/Release/*.dll
|
||||||
!node-pty/build/Release/*.node
|
!node-pty/build/Release/*.node
|
||||||
@@ -121,55 +117,8 @@ vsda/README.md
|
|||||||
vsda/targets
|
vsda/targets
|
||||||
!vsda/build/Release/vsda.node
|
!vsda/build/Release/vsda.node
|
||||||
|
|
||||||
vscode-encrypt/build/**
|
|
||||||
vscode-encrypt/src/**
|
|
||||||
vscode-encrypt/vendor/**
|
|
||||||
vscode-encrypt/.gitignore
|
|
||||||
vscode-encrypt/binding.gyp
|
|
||||||
vscode-encrypt/README.md
|
|
||||||
!vscode-encrypt/build/Release/vscode-encrypt-native.node
|
|
||||||
|
|
||||||
vscode-windows-ca-certs/**/*
|
vscode-windows-ca-certs/**/*
|
||||||
!vscode-windows-ca-certs/package.json
|
!vscode-windows-ca-certs/package.json
|
||||||
!vscode-windows-ca-certs/**/*.node
|
!vscode-windows-ca-certs/**/*.node
|
||||||
|
|
||||||
node-addon-api/**/*
|
node-addon-api/**/*
|
||||||
|
|
||||||
# other node modules
|
|
||||||
|
|
||||||
**/docs/**
|
|
||||||
**/example/**
|
|
||||||
**/examples/**
|
|
||||||
**/test/**
|
|
||||||
**/tests/**
|
|
||||||
|
|
||||||
**/History.md
|
|
||||||
**/CHANGELOG.md
|
|
||||||
**/README.md
|
|
||||||
**/readme.md
|
|
||||||
**/readme.markdown
|
|
||||||
|
|
||||||
**/*.ts
|
|
||||||
!typescript/**/*.d.ts
|
|
||||||
|
|
||||||
jschardet/dist/**
|
|
||||||
|
|
||||||
es6-promise/lib/**
|
|
||||||
|
|
||||||
vscode-textmate/webpack.config.js
|
|
||||||
|
|
||||||
# {{SQL CARBON EDIT }} We need more than just zone-node.js
|
|
||||||
# zone.js/dist/**
|
|
||||||
# !zone.js/dist/zone-node.js
|
|
||||||
|
|
||||||
# https://github.com/xtermjs/xterm.js/issues/3137
|
|
||||||
xterm/src/**
|
|
||||||
xterm/tsconfig.all.json
|
|
||||||
|
|
||||||
# https://github.com/xtermjs/xterm.js/issues/3138
|
|
||||||
xterm-addon-*/src/**
|
|
||||||
xterm-addon-*/fixtures/**
|
|
||||||
xterm-addon-*/out/**
|
|
||||||
xterm-addon-*/out-test/**
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
15
build/actions/copycat/action.yml
Normal file
15
build/actions/copycat/action.yml
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
name: Copycat
|
||||||
|
description: Copy all new issues to a different repo
|
||||||
|
inputs:
|
||||||
|
token:
|
||||||
|
description: GitHub token with issue, comment, and label read/write permissions to both repos
|
||||||
|
default: ${{ github.token }}
|
||||||
|
owner:
|
||||||
|
description: account/organization that owns the destination repo (the microsoft part of microsoft/vscode)
|
||||||
|
required: true
|
||||||
|
repo:
|
||||||
|
description: name of the destination repo (the vscode part of microsoft/vscode)
|
||||||
|
required: true
|
||||||
|
runs:
|
||||||
|
using: 'node12'
|
||||||
|
main: 'index.js'
|
||||||
19
build/actions/copycat/copyCat.js
Normal file
19
build/actions/copycat/copyCat.js
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
"use strict";
|
||||||
|
/*---------------------------------------------------------------------------------------------
|
||||||
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||||
|
*--------------------------------------------------------------------------------------------*/
|
||||||
|
Object.defineProperty(exports, "__esModule", { value: true });
|
||||||
|
class CopyCat {
|
||||||
|
constructor(github, owner, repo) {
|
||||||
|
this.github = github;
|
||||||
|
this.owner = owner;
|
||||||
|
this.repo = repo;
|
||||||
|
}
|
||||||
|
async run() {
|
||||||
|
const issue = await this.github.getIssue();
|
||||||
|
console.log(`Mirroring issue \`${issue.title}\` to ${this.owner}/${this.repo}`);
|
||||||
|
await this.github.createIssue(this.owner, this.repo, issue.title, issue.body.replace(/@|#|issues/g, '-'));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
exports.CopyCat = CopyCat;
|
||||||
21
build/actions/copycat/copyCat.ts
Normal file
21
build/actions/copycat/copyCat.ts
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
/*---------------------------------------------------------------------------------------------
|
||||||
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||||
|
*--------------------------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
import { GitHubIssue } from '../api/api'
|
||||||
|
|
||||||
|
export class CopyCat {
|
||||||
|
constructor(private github: GitHubIssue, private owner: string, private repo: string) {}
|
||||||
|
|
||||||
|
async run() {
|
||||||
|
const issue = await this.github.getIssue()
|
||||||
|
console.log(`Mirroring issue \`${issue.title}\` to ${this.owner}/${this.repo}`)
|
||||||
|
await this.github.createIssue(
|
||||||
|
this.owner,
|
||||||
|
this.repo,
|
||||||
|
issue.title,
|
||||||
|
issue.body.replace(/@|#|issues/g, '-'),
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
21
build/actions/copycat/index.js
Normal file
21
build/actions/copycat/index.js
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
"use strict";
|
||||||
|
/*---------------------------------------------------------------------------------------------
|
||||||
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||||
|
*--------------------------------------------------------------------------------------------*/
|
||||||
|
Object.defineProperty(exports, "__esModule", { value: true });
|
||||||
|
const core = require("@actions/core");
|
||||||
|
const github_1 = require("@actions/github");
|
||||||
|
const octokit_1 = require("../api/octokit");
|
||||||
|
const utils_1 = require("../utils/utils");
|
||||||
|
const copyCat_1 = require("./copyCat");
|
||||||
|
const token = utils_1.getRequiredInput('token');
|
||||||
|
const main = async () => {
|
||||||
|
await new copyCat_1.CopyCat(new octokit_1.OctoKitIssue(token, github_1.context.repo, { number: github_1.context.issue.number }), utils_1.getRequiredInput('owner'), utils_1.getRequiredInput('repo')).run();
|
||||||
|
};
|
||||||
|
main()
|
||||||
|
.then(() => utils_1.logRateLimit(token))
|
||||||
|
.catch(async (error) => {
|
||||||
|
core.setFailed(error.message);
|
||||||
|
await utils_1.logErrorToIssue(error.message, true, token);
|
||||||
|
});
|
||||||
27
build/actions/copycat/index.ts
Normal file
27
build/actions/copycat/index.ts
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
/*---------------------------------------------------------------------------------------------
|
||||||
|
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
|
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||||
|
*--------------------------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
import * as core from '@actions/core'
|
||||||
|
import { context } from '@actions/github'
|
||||||
|
import { OctoKitIssue } from '../api/octokit'
|
||||||
|
import { getRequiredInput, logErrorToIssue, logRateLimit } from '../utils/utils'
|
||||||
|
import { CopyCat } from './copyCat'
|
||||||
|
|
||||||
|
const token = getRequiredInput('token')
|
||||||
|
|
||||||
|
const main = async () => {
|
||||||
|
await new CopyCat(
|
||||||
|
new OctoKitIssue(token, context.repo, { number: context.issue.number }),
|
||||||
|
getRequiredInput('owner'),
|
||||||
|
getRequiredInput('repo'),
|
||||||
|
).run()
|
||||||
|
}
|
||||||
|
|
||||||
|
main()
|
||||||
|
.then(() => logRateLimit(token))
|
||||||
|
.catch(async (error) => {
|
||||||
|
core.setFailed(error.message)
|
||||||
|
await logErrorToIssue(error.message, true, token)
|
||||||
|
})
|
||||||
2
build/azure-pipelines/common/.gitignore
vendored
Normal file
2
build/azure-pipelines/common/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
node_modules/
|
||||||
|
*.js
|
||||||
@@ -1,25 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const fs = require("fs");
|
|
||||||
const path = require("path");
|
|
||||||
const crypto = require("crypto");
|
|
||||||
const { dirs } = require('../../npm/dirs');
|
|
||||||
const ROOT = path.join(__dirname, '../../../');
|
|
||||||
const shasum = crypto.createHash('sha1');
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'build/.cachesalt')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, '.yarnrc')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'remote/.yarnrc')));
|
|
||||||
// Add `yarn.lock` files
|
|
||||||
for (let dir of dirs) {
|
|
||||||
const yarnLockPath = path.join(ROOT, dir, 'yarn.lock');
|
|
||||||
shasum.update(fs.readFileSync(yarnLockPath));
|
|
||||||
}
|
|
||||||
// Add any other command line arguments
|
|
||||||
for (let i = 2; i < process.argv.length; i++) {
|
|
||||||
shasum.update(process.argv[i]);
|
|
||||||
}
|
|
||||||
process.stdout.write(shasum.digest('hex'));
|
|
||||||
@@ -1,32 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
import * as fs from 'fs';
|
|
||||||
import * as path from 'path';
|
|
||||||
import * as crypto from 'crypto';
|
|
||||||
const { dirs } = require('../../npm/dirs');
|
|
||||||
|
|
||||||
const ROOT = path.join(__dirname, '../../../');
|
|
||||||
|
|
||||||
const shasum = crypto.createHash('sha1');
|
|
||||||
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'build/.cachesalt')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, '.yarnrc')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'remote/.yarnrc')));
|
|
||||||
|
|
||||||
// Add `yarn.lock` files
|
|
||||||
for (let dir of dirs) {
|
|
||||||
const yarnLockPath = path.join(ROOT, dir, 'yarn.lock');
|
|
||||||
shasum.update(fs.readFileSync(yarnLockPath));
|
|
||||||
}
|
|
||||||
|
|
||||||
// Add any other command line arguments
|
|
||||||
for (let i = 2; i < process.argv.length; i++) {
|
|
||||||
shasum.update(process.argv[i]);
|
|
||||||
}
|
|
||||||
|
|
||||||
process.stdout.write(shasum.digest('hex'));
|
|
||||||
@@ -1,41 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const vfs = require("vinyl-fs");
|
|
||||||
const path = require("path");
|
|
||||||
const es = require("event-stream");
|
|
||||||
const fs = require("fs");
|
|
||||||
const files = [
|
|
||||||
'.build/langpacks/**/*.vsix',
|
|
||||||
'.build/extensions/**/*.vsix',
|
|
||||||
'.build/win32-x64/**/*.{exe,zip}',
|
|
||||||
'.build/linux/sha256hashes.txt',
|
|
||||||
'.build/linux/deb/amd64/deb/*.deb',
|
|
||||||
'.build/linux/rpm/x86_64/*.rpm',
|
|
||||||
'.build/linux/server/*',
|
|
||||||
'.build/linux/archive/*',
|
|
||||||
'.build/docker/*',
|
|
||||||
'.build/darwin/*',
|
|
||||||
'.build/version.json' // version information
|
|
||||||
];
|
|
||||||
async function main() {
|
|
||||||
return new Promise((resolve, reject) => {
|
|
||||||
const stream = vfs.src(files, { base: '.build', allowEmpty: true })
|
|
||||||
.pipe(es.through(file => {
|
|
||||||
const filePath = path.join(process.env.BUILD_ARTIFACTSTAGINGDIRECTORY,
|
|
||||||
//Preserve intermediate directories after .build folder
|
|
||||||
file.path.substr(path.resolve('.build').length + 1));
|
|
||||||
fs.mkdirSync(path.dirname(filePath), { recursive: true });
|
|
||||||
fs.renameSync(file.path, filePath);
|
|
||||||
}));
|
|
||||||
stream.on('end', () => resolve());
|
|
||||||
stream.on('error', e => reject(e));
|
|
||||||
});
|
|
||||||
}
|
|
||||||
main().catch(err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
@@ -11,7 +11,6 @@ import * as es from 'event-stream';
|
|||||||
import * as fs from 'fs';
|
import * as fs from 'fs';
|
||||||
|
|
||||||
const files = [
|
const files = [
|
||||||
'.build/langpacks/**/*.vsix', // langpacks
|
|
||||||
'.build/extensions/**/*.vsix', // external extensions
|
'.build/extensions/**/*.vsix', // external extensions
|
||||||
'.build/win32-x64/**/*.{exe,zip}', // windows binaries
|
'.build/win32-x64/**/*.{exe,zip}', // windows binaries
|
||||||
'.build/linux/sha256hashes.txt', // linux hashes
|
'.build/linux/sha256hashes.txt', // linux hashes
|
||||||
|
|||||||
@@ -1,94 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const fs = require("fs");
|
|
||||||
const crypto = require("crypto");
|
|
||||||
const azure = require("azure-storage");
|
|
||||||
const mime = require("mime");
|
|
||||||
const cosmos_1 = require("@azure/cosmos");
|
|
||||||
const retry_1 = require("./retry");
|
|
||||||
if (process.argv.length !== 6) {
|
|
||||||
console.error('Usage: node createAsset.js PLATFORM TYPE NAME FILE');
|
|
||||||
process.exit(-1);
|
|
||||||
}
|
|
||||||
function hashStream(hashName, stream) {
|
|
||||||
return new Promise((c, e) => {
|
|
||||||
const shasum = crypto.createHash(hashName);
|
|
||||||
stream
|
|
||||||
.on('data', shasum.update.bind(shasum))
|
|
||||||
.on('error', e)
|
|
||||||
.on('close', () => c(shasum.digest('hex')));
|
|
||||||
});
|
|
||||||
}
|
|
||||||
async function doesAssetExist(blobService, quality, blobName) {
|
|
||||||
const existsResult = await new Promise((c, e) => blobService.doesBlobExist(quality, blobName, (err, r) => err ? e(err) : c(r)));
|
|
||||||
return existsResult.exists;
|
|
||||||
}
|
|
||||||
async function uploadBlob(blobService, quality, blobName, filePath, fileName) {
|
|
||||||
const blobOptions = {
|
|
||||||
contentSettings: {
|
|
||||||
contentType: mime.lookup(filePath),
|
|
||||||
contentDisposition: `attachment; filename="${fileName}"`,
|
|
||||||
cacheControl: 'max-age=31536000, public'
|
|
||||||
}
|
|
||||||
};
|
|
||||||
await new Promise((c, e) => blobService.createBlockBlobFromLocalFile(quality, blobName, filePath, blobOptions, err => err ? e(err) : c()));
|
|
||||||
}
|
|
||||||
function getEnv(name) {
|
|
||||||
const result = process.env[name];
|
|
||||||
if (typeof result === 'undefined') {
|
|
||||||
throw new Error('Missing env: ' + name);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
async function main() {
|
|
||||||
const [, , platform, type, fileName, filePath] = process.argv;
|
|
||||||
const quality = getEnv('VSCODE_QUALITY');
|
|
||||||
const commit = getEnv('BUILD_SOURCEVERSION');
|
|
||||||
console.log('Creating asset...');
|
|
||||||
const stat = await new Promise((c, e) => fs.stat(filePath, (err, stat) => err ? e(err) : c(stat)));
|
|
||||||
const size = stat.size;
|
|
||||||
console.log('Size:', size);
|
|
||||||
const stream = fs.createReadStream(filePath);
|
|
||||||
const [sha1hash, sha256hash] = await Promise.all([hashStream('sha1', stream), hashStream('sha256', stream)]);
|
|
||||||
console.log('SHA1:', sha1hash);
|
|
||||||
console.log('SHA256:', sha256hash);
|
|
||||||
const blobName = commit + '/' + fileName;
|
|
||||||
const storageAccount = process.env['AZURE_STORAGE_ACCOUNT_2'];
|
|
||||||
const blobService = azure.createBlobService(storageAccount, process.env['AZURE_STORAGE_ACCESS_KEY_2'])
|
|
||||||
.withFilter(new azure.ExponentialRetryPolicyFilter(20));
|
|
||||||
const blobExists = await doesAssetExist(blobService, quality, blobName);
|
|
||||||
if (blobExists) {
|
|
||||||
console.log(`Blob ${quality}, ${blobName} already exists, not publishing again.`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
console.log('Uploading blobs to Azure storage...');
|
|
||||||
await uploadBlob(blobService, quality, blobName, filePath, fileName);
|
|
||||||
console.log('Blobs successfully uploaded.');
|
|
||||||
const asset = {
|
|
||||||
platform,
|
|
||||||
type,
|
|
||||||
url: `${process.env['AZURE_CDN_URL']}/${quality}/${blobName}`,
|
|
||||||
hash: sha1hash,
|
|
||||||
sha256hash,
|
|
||||||
size
|
|
||||||
};
|
|
||||||
// Remove this if we ever need to rollback fast updates for windows
|
|
||||||
if (/win32/.test(platform)) {
|
|
||||||
asset.supportsFastUpdate = true;
|
|
||||||
}
|
|
||||||
console.log('Asset:', JSON.stringify(asset, null, ' '));
|
|
||||||
const client = new cosmos_1.CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT'], key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const scripts = client.database('builds').container(quality).scripts;
|
|
||||||
await retry_1.retry(() => scripts.storedProcedure('createAsset').execute('', [commit, asset, true]));
|
|
||||||
}
|
|
||||||
main().then(() => {
|
|
||||||
console.log('Asset successfully created');
|
|
||||||
process.exit(0);
|
|
||||||
}, err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
@@ -11,7 +11,6 @@ import * as crypto from 'crypto';
|
|||||||
import * as azure from 'azure-storage';
|
import * as azure from 'azure-storage';
|
||||||
import * as mime from 'mime';
|
import * as mime from 'mime';
|
||||||
import { CosmosClient } from '@azure/cosmos';
|
import { CosmosClient } from '@azure/cosmos';
|
||||||
import { retry } from './retry';
|
|
||||||
|
|
||||||
interface Asset {
|
interface Asset {
|
||||||
platform: string;
|
platform: string;
|
||||||
@@ -122,7 +121,7 @@ async function main(): Promise<void> {
|
|||||||
|
|
||||||
const client = new CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT']!, key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
const client = new CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT']!, key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
||||||
const scripts = client.database('builds').container(quality).scripts;
|
const scripts = client.database('builds').container(quality).scripts;
|
||||||
await retry(() => scripts.storedProcedure('createAsset').execute('', [commit, asset, true]));
|
await scripts.storedProcedure('createAsset').execute('', [commit, asset, true]);
|
||||||
}
|
}
|
||||||
|
|
||||||
main().then(() => {
|
main().then(() => {
|
||||||
|
|||||||
@@ -1,51 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const cosmos_1 = require("@azure/cosmos");
|
|
||||||
const retry_1 = require("./retry");
|
|
||||||
if (process.argv.length !== 3) {
|
|
||||||
console.error('Usage: node createBuild.js VERSION');
|
|
||||||
process.exit(-1);
|
|
||||||
}
|
|
||||||
function getEnv(name) {
|
|
||||||
const result = process.env[name];
|
|
||||||
if (typeof result === 'undefined') {
|
|
||||||
throw new Error('Missing env: ' + name);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
async function main() {
|
|
||||||
const [, , _version] = process.argv;
|
|
||||||
const quality = getEnv('VSCODE_QUALITY');
|
|
||||||
const commit = getEnv('BUILD_SOURCEVERSION');
|
|
||||||
const queuedBy = getEnv('BUILD_QUEUEDBY');
|
|
||||||
const sourceBranch = getEnv('BUILD_SOURCEBRANCH');
|
|
||||||
const version = _version + (quality === 'stable' ? '' : `-${quality}`);
|
|
||||||
console.log('Creating build...');
|
|
||||||
console.log('Quality:', quality);
|
|
||||||
console.log('Version:', version);
|
|
||||||
console.log('Commit:', commit);
|
|
||||||
const build = {
|
|
||||||
id: commit,
|
|
||||||
timestamp: (new Date()).getTime(),
|
|
||||||
version,
|
|
||||||
isReleased: false,
|
|
||||||
sourceBranch,
|
|
||||||
queuedBy,
|
|
||||||
assets: [],
|
|
||||||
updates: {}
|
|
||||||
};
|
|
||||||
const client = new cosmos_1.CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT'], key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const scripts = client.database('builds').container(quality).scripts;
|
|
||||||
await retry_1.retry(() => scripts.storedProcedure('createBuild').execute('', [Object.assign(Object.assign({}, build), { _partitionKey: '' })]));
|
|
||||||
}
|
|
||||||
main().then(() => {
|
|
||||||
console.log('Build successfully created');
|
|
||||||
process.exit(0);
|
|
||||||
}, err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
@@ -6,7 +6,6 @@
|
|||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
import { CosmosClient } from '@azure/cosmos';
|
import { CosmosClient } from '@azure/cosmos';
|
||||||
import { retry } from './retry';
|
|
||||||
|
|
||||||
if (process.argv.length !== 3) {
|
if (process.argv.length !== 3) {
|
||||||
console.error('Usage: node createBuild.js VERSION');
|
console.error('Usage: node createBuild.js VERSION');
|
||||||
@@ -49,7 +48,7 @@ async function main(): Promise<void> {
|
|||||||
|
|
||||||
const client = new CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT']!, key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
const client = new CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT']!, key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
||||||
const scripts = client.database('builds').container(quality).scripts;
|
const scripts = client.database('builds').container(quality).scripts;
|
||||||
await retry(() => scripts.storedProcedure('createBuild').execute('', [{ ...build, _partitionKey: '' }]));
|
await scripts.storedProcedure('createBuild').execute('', [{ ...build, _partitionKey: '' }]);
|
||||||
}
|
}
|
||||||
|
|
||||||
main().then(() => {
|
main().then(() => {
|
||||||
|
|||||||
@@ -10,8 +10,8 @@ git clone --depth 1 https://github.com/Microsoft/vscode-node-debug2.git
|
|||||||
git clone --depth 1 https://github.com/Microsoft/vscode-node-debug.git
|
git clone --depth 1 https://github.com/Microsoft/vscode-node-debug.git
|
||||||
git clone --depth 1 https://github.com/Microsoft/vscode-html-languageservice.git
|
git clone --depth 1 https://github.com/Microsoft/vscode-html-languageservice.git
|
||||||
git clone --depth 1 https://github.com/Microsoft/vscode-json-languageservice.git
|
git clone --depth 1 https://github.com/Microsoft/vscode-json-languageservice.git
|
||||||
node $BUILD_SOURCESDIRECTORY/node_modules/.bin/vscode-telemetry-extractor --sourceDir $BUILD_SOURCESDIRECTORY --excludedDir $BUILD_SOURCESDIRECTORY/extensions --outputDir . --applyEndpoints
|
node $BUILD_SOURCESDIRECTORY/build/node_modules/.bin/vscode-telemetry-extractor --sourceDir $BUILD_SOURCESDIRECTORY --excludedDir $BUILD_SOURCESDIRECTORY/extensions --outputDir . --applyEndpoints
|
||||||
node $BUILD_SOURCESDIRECTORY/node_modules/.bin/vscode-telemetry-extractor --config $BUILD_SOURCESDIRECTORY/build/azure-pipelines/common/telemetry-config.json -o .
|
node $BUILD_SOURCESDIRECTORY/build/node_modules/.bin/vscode-telemetry-extractor --config $BUILD_SOURCESDIRECTORY/build/azure-pipelines/common/telemetry-config.json -o .
|
||||||
mkdir -p $BUILD_SOURCESDIRECTORY/.build/telemetry
|
mkdir -p $BUILD_SOURCESDIRECTORY/.build/telemetry
|
||||||
mv declarations-resolved.json $BUILD_SOURCESDIRECTORY/.build/telemetry/telemetry-core.json
|
mv declarations-resolved.json $BUILD_SOURCESDIRECTORY/.build/telemetry/telemetry-core.json
|
||||||
mv config-resolved.json $BUILD_SOURCESDIRECTORY/.build/telemetry/telemetry-extensions.json
|
mv config-resolved.json $BUILD_SOURCESDIRECTORY/.build/telemetry/telemetry-extensions.json
|
||||||
|
|||||||
@@ -1,14 +0,0 @@
|
|||||||
"use strict";
|
|
||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const path = require("path");
|
|
||||||
const retry_1 = require("./retry");
|
|
||||||
const { installBrowsersWithProgressBar } = require('playwright/lib/install/installer');
|
|
||||||
const playwrightPath = path.dirname(require.resolve('playwright'));
|
|
||||||
async function install() {
|
|
||||||
await retry_1.retry(() => installBrowsersWithProgressBar(playwrightPath));
|
|
||||||
}
|
|
||||||
install();
|
|
||||||
@@ -1,40 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const fs = require("fs");
|
|
||||||
const path = require("path");
|
|
||||||
if (process.argv.length !== 3) {
|
|
||||||
console.error('Usage: node listNodeModules.js OUTPUT_FILE');
|
|
||||||
process.exit(-1);
|
|
||||||
}
|
|
||||||
const ROOT = path.join(__dirname, '../../../');
|
|
||||||
function findNodeModulesFiles(location, inNodeModules, result) {
|
|
||||||
const entries = fs.readdirSync(path.join(ROOT, location));
|
|
||||||
for (const entry of entries) {
|
|
||||||
const entryPath = `${location}/${entry}`;
|
|
||||||
if (/(^\/out)|(^\/src$)|(^\/.git$)|(^\/.build$)/.test(entryPath)) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
let stat;
|
|
||||||
try {
|
|
||||||
stat = fs.statSync(path.join(ROOT, entryPath));
|
|
||||||
}
|
|
||||||
catch (err) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
if (stat.isDirectory()) {
|
|
||||||
findNodeModulesFiles(entryPath, inNodeModules || (entry === 'node_modules'), result);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
if (inNodeModules) {
|
|
||||||
result.push(entryPath.substr(1));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const result = [];
|
|
||||||
findNodeModulesFiles('', false, result);
|
|
||||||
fs.writeFileSync(process.argv[2], result.join('\n') + '\n');
|
|
||||||
@@ -1,46 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
import * as fs from 'fs';
|
|
||||||
import * as path from 'path';
|
|
||||||
|
|
||||||
if (process.argv.length !== 3) {
|
|
||||||
console.error('Usage: node listNodeModules.js OUTPUT_FILE');
|
|
||||||
process.exit(-1);
|
|
||||||
}
|
|
||||||
|
|
||||||
const ROOT = path.join(__dirname, '../../../');
|
|
||||||
|
|
||||||
function findNodeModulesFiles(location: string, inNodeModules: boolean, result: string[]) {
|
|
||||||
const entries = fs.readdirSync(path.join(ROOT, location));
|
|
||||||
for (const entry of entries) {
|
|
||||||
const entryPath = `${location}/${entry}`;
|
|
||||||
|
|
||||||
if (/(^\/out)|(^\/src$)|(^\/.git$)|(^\/.build$)/.test(entryPath)) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
let stat: fs.Stats;
|
|
||||||
try {
|
|
||||||
stat = fs.statSync(path.join(ROOT, entryPath));
|
|
||||||
} catch (err) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (stat.isDirectory()) {
|
|
||||||
findNodeModulesFiles(entryPath, inNodeModules || (entry === 'node_modules'), result);
|
|
||||||
} else {
|
|
||||||
if (inNodeModules) {
|
|
||||||
result.push(entryPath.substr(1));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
const result: string[] = [];
|
|
||||||
findNodeModulesFiles('', false, result);
|
|
||||||
fs.writeFileSync(process.argv[2], result.join('\n') + '\n');
|
|
||||||
@@ -1,71 +0,0 @@
|
|||||||
"use strict";
|
|
||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const azure = require("azure-storage");
|
|
||||||
const mime = require("mime");
|
|
||||||
const minimist = require("minimist");
|
|
||||||
const path_1 = require("path");
|
|
||||||
const fileNames = [
|
|
||||||
'fake.html',
|
|
||||||
'host.js',
|
|
||||||
'index.html',
|
|
||||||
'main.js',
|
|
||||||
'service-worker.js'
|
|
||||||
];
|
|
||||||
async function assertContainer(blobService, container) {
|
|
||||||
await new Promise((c, e) => blobService.createContainerIfNotExists(container, { publicAccessLevel: 'blob' }, err => err ? e(err) : c()));
|
|
||||||
}
|
|
||||||
async function doesBlobExist(blobService, container, blobName) {
|
|
||||||
const existsResult = await new Promise((c, e) => blobService.doesBlobExist(container, blobName, (err, r) => err ? e(err) : c(r)));
|
|
||||||
return existsResult.exists;
|
|
||||||
}
|
|
||||||
async function uploadBlob(blobService, container, blobName, file) {
|
|
||||||
const blobOptions = {
|
|
||||||
contentSettings: {
|
|
||||||
contentType: mime.lookup(file),
|
|
||||||
cacheControl: 'max-age=31536000, public'
|
|
||||||
}
|
|
||||||
};
|
|
||||||
await new Promise((c, e) => blobService.createBlockBlobFromLocalFile(container, blobName, file, blobOptions, err => err ? e(err) : c()));
|
|
||||||
}
|
|
||||||
async function publish(commit, files) {
|
|
||||||
console.log('Publishing...');
|
|
||||||
console.log('Commit:', commit);
|
|
||||||
const storageAccount = process.env['AZURE_WEBVIEW_STORAGE_ACCOUNT'];
|
|
||||||
const blobService = azure.createBlobService(storageAccount, process.env['AZURE_WEBVIEW_STORAGE_ACCESS_KEY'])
|
|
||||||
.withFilter(new azure.ExponentialRetryPolicyFilter(20));
|
|
||||||
await assertContainer(blobService, commit);
|
|
||||||
for (const file of files) {
|
|
||||||
const blobName = path_1.basename(file);
|
|
||||||
const blobExists = await doesBlobExist(blobService, commit, blobName);
|
|
||||||
if (blobExists) {
|
|
||||||
console.log(`Blob ${commit}, ${blobName} already exists, not publishing again.`);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
console.log('Uploading blob to Azure storage...');
|
|
||||||
await uploadBlob(blobService, commit, blobName, file);
|
|
||||||
}
|
|
||||||
console.log('Blobs successfully uploaded.');
|
|
||||||
}
|
|
||||||
function main() {
|
|
||||||
const commit = process.env['BUILD_SOURCEVERSION'];
|
|
||||||
if (!commit) {
|
|
||||||
console.warn('Skipping publish due to missing BUILD_SOURCEVERSION');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const opts = minimist(process.argv.slice(2));
|
|
||||||
const [directory] = opts._;
|
|
||||||
const files = fileNames.map(fileName => path_1.join(directory, fileName));
|
|
||||||
publish(commit, files).catch(err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
if (process.argv.length < 3) {
|
|
||||||
console.error('Usage: node publish.js <directory>');
|
|
||||||
process.exit(-1);
|
|
||||||
}
|
|
||||||
main();
|
|
||||||
@@ -1,224 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const fs = require("fs");
|
|
||||||
const crypto = require("crypto");
|
|
||||||
const azure = require("azure-storage");
|
|
||||||
const mime = require("mime");
|
|
||||||
const minimist = require("minimist");
|
|
||||||
const documentdb_1 = require("documentdb");
|
|
||||||
// {{SQL CARBON EDIT}}
|
|
||||||
if (process.argv.length < 9) {
|
|
||||||
console.error('Usage: node publish.js <product_quality> <platform> <file_type> <file_name> <version> <is_update> <file> [commit_id]');
|
|
||||||
process.exit(-1);
|
|
||||||
}
|
|
||||||
function hashStream(hashName, stream) {
|
|
||||||
return new Promise((c, e) => {
|
|
||||||
const shasum = crypto.createHash(hashName);
|
|
||||||
stream
|
|
||||||
.on('data', shasum.update.bind(shasum))
|
|
||||||
.on('error', e)
|
|
||||||
.on('close', () => c(shasum.digest('hex')));
|
|
||||||
});
|
|
||||||
}
|
|
||||||
function createDefaultConfig(quality) {
|
|
||||||
return {
|
|
||||||
id: quality,
|
|
||||||
frozen: false
|
|
||||||
};
|
|
||||||
}
|
|
||||||
function getConfig(quality) {
|
|
||||||
console.log(`Getting config for quality ${quality}`);
|
|
||||||
const client = new documentdb_1.DocumentClient(process.env['AZURE_DOCUMENTDB_ENDPOINT'], { masterKey: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const collection = 'dbs/builds/colls/config';
|
|
||||||
const query = {
|
|
||||||
query: `SELECT TOP 1 * FROM c WHERE c.id = @quality`,
|
|
||||||
parameters: [
|
|
||||||
{ name: '@quality', value: quality }
|
|
||||||
]
|
|
||||||
};
|
|
||||||
return retry(() => new Promise((c, e) => {
|
|
||||||
client.queryDocuments(collection, query, { enableCrossPartitionQuery: true }).toArray((err, results) => {
|
|
||||||
if (err && err.code !== 409) {
|
|
||||||
return e(err);
|
|
||||||
}
|
|
||||||
c(!results || results.length === 0 ? createDefaultConfig(quality) : results[0]);
|
|
||||||
});
|
|
||||||
}));
|
|
||||||
}
|
|
||||||
function createOrUpdate(commit, quality, platform, type, release, asset, isUpdate) {
|
|
||||||
const client = new documentdb_1.DocumentClient(process.env['AZURE_DOCUMENTDB_ENDPOINT'], { masterKey: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const collection = 'dbs/builds/colls/' + quality;
|
|
||||||
const updateQuery = {
|
|
||||||
query: 'SELECT TOP 1 * FROM c WHERE c.id = @id',
|
|
||||||
parameters: [{ name: '@id', value: commit }]
|
|
||||||
};
|
|
||||||
let updateTries = 0;
|
|
||||||
function update() {
|
|
||||||
updateTries++;
|
|
||||||
return new Promise((c, e) => {
|
|
||||||
console.log(`Querying existing documents to update...`);
|
|
||||||
client.queryDocuments(collection, updateQuery, { enableCrossPartitionQuery: true }).toArray((err, results) => {
|
|
||||||
if (err) {
|
|
||||||
return e(err);
|
|
||||||
}
|
|
||||||
if (results.length !== 1) {
|
|
||||||
return e(new Error('No documents'));
|
|
||||||
}
|
|
||||||
const release = results[0];
|
|
||||||
release.assets = [
|
|
||||||
...release.assets.filter((a) => !(a.platform === platform && a.type === type)),
|
|
||||||
asset
|
|
||||||
];
|
|
||||||
if (isUpdate) {
|
|
||||||
release.updates[platform] = type;
|
|
||||||
}
|
|
||||||
console.log(`Replacing existing document with updated version`);
|
|
||||||
client.replaceDocument(release._self, release, err => {
|
|
||||||
if (err && err.code === 409 && updateTries < 5) {
|
|
||||||
return c(update());
|
|
||||||
}
|
|
||||||
if (err) {
|
|
||||||
return e(err);
|
|
||||||
}
|
|
||||||
console.log('Build successfully updated.');
|
|
||||||
c();
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
return retry(() => new Promise((c, e) => {
|
|
||||||
console.log(`Attempting to create document`);
|
|
||||||
client.createDocument(collection, release, err => {
|
|
||||||
if (err && err.code === 409) {
|
|
||||||
return c(update());
|
|
||||||
}
|
|
||||||
if (err) {
|
|
||||||
return e(err);
|
|
||||||
}
|
|
||||||
console.log('Build successfully published.');
|
|
||||||
c();
|
|
||||||
});
|
|
||||||
}));
|
|
||||||
}
|
|
||||||
async function assertContainer(blobService, quality) {
|
|
||||||
await new Promise((c, e) => blobService.createContainerIfNotExists(quality, { publicAccessLevel: 'blob' }, err => err ? e(err) : c()));
|
|
||||||
}
|
|
||||||
async function doesAssetExist(blobService, quality, blobName) {
|
|
||||||
const existsResult = await new Promise((c, e) => blobService.doesBlobExist(quality, blobName, (err, r) => err ? e(err) : c(r)));
|
|
||||||
return existsResult.exists;
|
|
||||||
}
|
|
||||||
async function uploadBlob(blobService, quality, blobName, file) {
|
|
||||||
const blobOptions = {
|
|
||||||
contentSettings: {
|
|
||||||
contentType: mime.lookup(file),
|
|
||||||
cacheControl: 'max-age=31536000, public'
|
|
||||||
}
|
|
||||||
};
|
|
||||||
await new Promise((c, e) => blobService.createBlockBlobFromLocalFile(quality, blobName, file, blobOptions, err => err ? e(err) : c()));
|
|
||||||
}
|
|
||||||
async function publish(commit, quality, platform, type, name, version, _isUpdate, file, opts) {
|
|
||||||
const isUpdate = _isUpdate === 'true';
|
|
||||||
const queuedBy = process.env['BUILD_QUEUEDBY'];
|
|
||||||
const sourceBranch = process.env['BUILD_SOURCEBRANCH'];
|
|
||||||
console.log('Publishing...');
|
|
||||||
console.log('Quality:', quality);
|
|
||||||
console.log('Platform:', platform);
|
|
||||||
console.log('Type:', type);
|
|
||||||
console.log('Name:', name);
|
|
||||||
console.log('Version:', version);
|
|
||||||
console.log('Commit:', commit);
|
|
||||||
console.log('Is Update:', isUpdate);
|
|
||||||
console.log('File:', file);
|
|
||||||
const stat = await new Promise((c, e) => fs.stat(file, (err, stat) => err ? e(err) : c(stat)));
|
|
||||||
const size = stat.size;
|
|
||||||
console.log('Size:', size);
|
|
||||||
const stream = fs.createReadStream(file);
|
|
||||||
const [sha1hash, sha256hash] = await Promise.all([hashStream('sha1', stream), hashStream('sha256', stream)]);
|
|
||||||
console.log('SHA1:', sha1hash);
|
|
||||||
console.log('SHA256:', sha256hash);
|
|
||||||
const blobName = commit + '/' + name;
|
|
||||||
const storageAccount = process.env['AZURE_STORAGE_ACCOUNT_2'];
|
|
||||||
const blobService = azure.createBlobService(storageAccount, process.env['AZURE_STORAGE_ACCESS_KEY_2'])
|
|
||||||
.withFilter(new azure.ExponentialRetryPolicyFilter(20));
|
|
||||||
await assertContainer(blobService, quality);
|
|
||||||
const blobExists = await doesAssetExist(blobService, quality, blobName);
|
|
||||||
if (blobExists) {
|
|
||||||
console.log(`Blob ${quality}, ${blobName} already exists, not publishing again.`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
console.log('Uploading blobs to Azure storage...');
|
|
||||||
await uploadBlob(blobService, quality, blobName, file);
|
|
||||||
console.log('Blobs successfully uploaded.');
|
|
||||||
const config = await getConfig(quality);
|
|
||||||
console.log('Quality config:', config);
|
|
||||||
const asset = {
|
|
||||||
platform: platform,
|
|
||||||
type: type,
|
|
||||||
url: `${process.env['AZURE_CDN_URL']}/${quality}/${blobName}`,
|
|
||||||
hash: sha1hash,
|
|
||||||
sha256hash,
|
|
||||||
size
|
|
||||||
};
|
|
||||||
// Remove this if we ever need to rollback fast updates for windows
|
|
||||||
if (/win32/.test(platform)) {
|
|
||||||
asset.supportsFastUpdate = true;
|
|
||||||
}
|
|
||||||
console.log('Asset:', JSON.stringify(asset, null, ' '));
|
|
||||||
// {{SQL CARBON EDIT}}
|
|
||||||
// Insiders: nightly build from main
|
|
||||||
const isReleased = (((quality === 'insider' && /^main$|^refs\/heads\/main$/.test(sourceBranch)) ||
|
|
||||||
(quality === 'rc1' && /^release\/|^refs\/heads\/release\//.test(sourceBranch))) &&
|
|
||||||
/Project Collection Service Accounts|Microsoft.VisualStudio.Services.TFS/.test(queuedBy));
|
|
||||||
const release = {
|
|
||||||
id: commit,
|
|
||||||
timestamp: (new Date()).getTime(),
|
|
||||||
version,
|
|
||||||
isReleased: isReleased,
|
|
||||||
sourceBranch,
|
|
||||||
queuedBy,
|
|
||||||
assets: [],
|
|
||||||
updates: {}
|
|
||||||
};
|
|
||||||
if (!opts['upload-only']) {
|
|
||||||
release.assets.push(asset);
|
|
||||||
if (isUpdate) {
|
|
||||||
release.updates[platform] = type;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
await createOrUpdate(commit, quality, platform, type, release, asset, isUpdate);
|
|
||||||
}
|
|
||||||
const RETRY_TIMES = 10;
|
|
||||||
async function retry(fn) {
|
|
||||||
for (let run = 1; run <= RETRY_TIMES; run++) {
|
|
||||||
try {
|
|
||||||
return await fn();
|
|
||||||
}
|
|
||||||
catch (err) {
|
|
||||||
if (!/ECONNRESET/.test(err.message)) {
|
|
||||||
throw err;
|
|
||||||
}
|
|
||||||
console.log(`Caught error ${err} - ${run}/${RETRY_TIMES}`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
throw new Error('Retried too many times');
|
|
||||||
}
|
|
||||||
function main() {
|
|
||||||
const commit = process.env['BUILD_SOURCEVERSION'];
|
|
||||||
if (!commit) {
|
|
||||||
console.warn('Skipping publish due to missing BUILD_SOURCEVERSION');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const opts = minimist(process.argv.slice(2), {
|
|
||||||
boolean: ['upload-only']
|
|
||||||
});
|
|
||||||
const [quality, platform, type, name, version, _isUpdate, file] = opts._;
|
|
||||||
publish(commit, quality, platform, type, name, version, _isUpdate, file, opts).catch(err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
main();
|
|
||||||
@@ -1,91 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const documentdb_1 = require("documentdb");
|
|
||||||
function createDefaultConfig(quality) {
|
|
||||||
return {
|
|
||||||
id: quality,
|
|
||||||
frozen: false
|
|
||||||
};
|
|
||||||
}
|
|
||||||
function getConfig(quality) {
|
|
||||||
const client = new documentdb_1.DocumentClient(process.env['AZURE_DOCUMENTDB_ENDPOINT'], { masterKey: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const collection = 'dbs/builds/colls/config';
|
|
||||||
const query = {
|
|
||||||
query: `SELECT TOP 1 * FROM c WHERE c.id = @quality`,
|
|
||||||
parameters: [
|
|
||||||
{ name: '@quality', value: quality }
|
|
||||||
]
|
|
||||||
};
|
|
||||||
return new Promise((c, e) => {
|
|
||||||
client.queryDocuments(collection, query).toArray((err, results) => {
|
|
||||||
if (err && err.code !== 409) {
|
|
||||||
return e(err);
|
|
||||||
}
|
|
||||||
c(!results || results.length === 0 ? createDefaultConfig(quality) : results[0]);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
function doRelease(commit, quality) {
|
|
||||||
const client = new documentdb_1.DocumentClient(process.env['AZURE_DOCUMENTDB_ENDPOINT'], { masterKey: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const collection = 'dbs/builds/colls/' + quality;
|
|
||||||
const query = {
|
|
||||||
query: 'SELECT TOP 1 * FROM c WHERE c.id = @id',
|
|
||||||
parameters: [{ name: '@id', value: commit }]
|
|
||||||
};
|
|
||||||
let updateTries = 0;
|
|
||||||
function update() {
|
|
||||||
updateTries++;
|
|
||||||
return new Promise((c, e) => {
|
|
||||||
client.queryDocuments(collection, query).toArray((err, results) => {
|
|
||||||
if (err) {
|
|
||||||
return e(err);
|
|
||||||
}
|
|
||||||
if (results.length !== 1) {
|
|
||||||
return e(new Error('No documents'));
|
|
||||||
}
|
|
||||||
const release = results[0];
|
|
||||||
release.isReleased = true;
|
|
||||||
client.replaceDocument(release._self, release, err => {
|
|
||||||
if (err && err.code === 409 && updateTries < 5) {
|
|
||||||
return c(update());
|
|
||||||
}
|
|
||||||
if (err) {
|
|
||||||
return e(err);
|
|
||||||
}
|
|
||||||
console.log('Build successfully updated.');
|
|
||||||
c();
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
return update();
|
|
||||||
}
|
|
||||||
async function release(commit, quality) {
|
|
||||||
const config = await getConfig(quality);
|
|
||||||
console.log('Quality config:', config);
|
|
||||||
if (config.frozen) {
|
|
||||||
console.log(`Skipping release because quality ${quality} is frozen.`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
await doRelease(commit, quality);
|
|
||||||
}
|
|
||||||
function env(name) {
|
|
||||||
const result = process.env[name];
|
|
||||||
if (!result) {
|
|
||||||
throw new Error(`Skipping release due to missing env: ${name}`);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
async function main() {
|
|
||||||
const commit = env('BUILD_SOURCEVERSION');
|
|
||||||
const quality = env('VSCODE_QUALITY');
|
|
||||||
await release(commit, quality);
|
|
||||||
}
|
|
||||||
main().catch(err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
@@ -1,50 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const cosmos_1 = require("@azure/cosmos");
|
|
||||||
const retry_1 = require("./retry");
|
|
||||||
function getEnv(name) {
|
|
||||||
const result = process.env[name];
|
|
||||||
if (typeof result === 'undefined') {
|
|
||||||
throw new Error('Missing env: ' + name);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
function createDefaultConfig(quality) {
|
|
||||||
return {
|
|
||||||
id: quality,
|
|
||||||
frozen: false
|
|
||||||
};
|
|
||||||
}
|
|
||||||
async function getConfig(client, quality) {
|
|
||||||
const query = `SELECT TOP 1 * FROM c WHERE c.id = "${quality}"`;
|
|
||||||
const res = await client.database('builds').container('config').items.query(query).fetchAll();
|
|
||||||
if (res.resources.length === 0) {
|
|
||||||
return createDefaultConfig(quality);
|
|
||||||
}
|
|
||||||
return res.resources[0];
|
|
||||||
}
|
|
||||||
async function main() {
|
|
||||||
const commit = getEnv('BUILD_SOURCEVERSION');
|
|
||||||
const quality = getEnv('VSCODE_QUALITY');
|
|
||||||
const client = new cosmos_1.CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT'], key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const config = await getConfig(client, quality);
|
|
||||||
console.log('Quality config:', config);
|
|
||||||
if (config.frozen) {
|
|
||||||
console.log(`Skipping release because quality ${quality} is frozen.`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
console.log(`Releasing build ${commit}...`);
|
|
||||||
const scripts = client.database('builds').container(quality).scripts;
|
|
||||||
await retry_1.retry(() => scripts.storedProcedure('releaseBuild').execute('', [commit]));
|
|
||||||
}
|
|
||||||
main().then(() => {
|
|
||||||
console.log('Build successfully released');
|
|
||||||
process.exit(0);
|
|
||||||
}, err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
@@ -6,7 +6,6 @@
|
|||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
import { CosmosClient } from '@azure/cosmos';
|
import { CosmosClient } from '@azure/cosmos';
|
||||||
import { retry } from './retry';
|
|
||||||
|
|
||||||
function getEnv(name: string): string {
|
function getEnv(name: string): string {
|
||||||
const result = process.env[name];
|
const result = process.env[name];
|
||||||
@@ -59,7 +58,7 @@ async function main(): Promise<void> {
|
|||||||
console.log(`Releasing build ${commit}...`);
|
console.log(`Releasing build ${commit}...`);
|
||||||
|
|
||||||
const scripts = client.database('builds').container(quality).scripts;
|
const scripts = client.database('builds').container(quality).scripts;
|
||||||
await retry(() => scripts.storedProcedure('releaseBuild').execute('', [commit]));
|
await scripts.storedProcedure('releaseBuild').execute('', [commit]);
|
||||||
}
|
}
|
||||||
|
|
||||||
main().then(() => {
|
main().then(() => {
|
||||||
|
|||||||
@@ -1,25 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
exports.retry = void 0;
|
|
||||||
async function retry(fn) {
|
|
||||||
for (let run = 1; run <= 10; run++) {
|
|
||||||
try {
|
|
||||||
return await fn();
|
|
||||||
}
|
|
||||||
catch (err) {
|
|
||||||
if (!/ECONNRESET/.test(err.message)) {
|
|
||||||
throw err;
|
|
||||||
}
|
|
||||||
const millis = (Math.random() * 200) + (50 * Math.pow(1.5, run));
|
|
||||||
console.log(`Failed with ECONNRESET, retrying in ${millis}ms...`);
|
|
||||||
// maximum delay is 10th retry: ~3 seconds
|
|
||||||
await new Promise(c => setTimeout(c, millis));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
throw new Error('Retried too many times');
|
|
||||||
}
|
|
||||||
exports.retry = retry;
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
export async function retry<T>(fn: () => Promise<T>): Promise<T> {
|
|
||||||
for (let run = 1; run <= 10; run++) {
|
|
||||||
try {
|
|
||||||
return await fn();
|
|
||||||
} catch (err) {
|
|
||||||
if (!/ECONNRESET/.test(err.message)) {
|
|
||||||
throw err;
|
|
||||||
}
|
|
||||||
|
|
||||||
const millis = (Math.random() * 200) + (50 * Math.pow(1.5, run));
|
|
||||||
console.log(`Failed with ECONNRESET, retrying in ${millis}ms...`);
|
|
||||||
|
|
||||||
// maximum delay is 10th retry: ~3 seconds
|
|
||||||
await new Promise(c => setTimeout(c, millis));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
throw new Error('Retried too many times');
|
|
||||||
}
|
|
||||||
@@ -1,47 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const fs = require("fs");
|
|
||||||
const path = require("path");
|
|
||||||
const crypto = require("crypto");
|
|
||||||
const ROOT = path.join(__dirname, '../../../');
|
|
||||||
function findFiles(location, pattern, result) {
|
|
||||||
const entries = fs.readdirSync(path.join(ROOT, location));
|
|
||||||
for (const entry of entries) {
|
|
||||||
const entryPath = `${location}/${entry}`;
|
|
||||||
let stat;
|
|
||||||
try {
|
|
||||||
stat = fs.statSync(path.join(ROOT, entryPath));
|
|
||||||
}
|
|
||||||
catch (err) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
if (stat.isDirectory()) {
|
|
||||||
findFiles(entryPath, pattern, result);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
if (stat.isFile() && entry.endsWith(pattern)) {
|
|
||||||
result.push(path.join(ROOT, entryPath));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const shasum = crypto.createHash('sha1');
|
|
||||||
/**
|
|
||||||
* Creating a sha hash of all the files that can cause packages to change/redownload.
|
|
||||||
*/
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'build/.cachesalt')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, '.yarnrc')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'remote/.yarnrc')));
|
|
||||||
// Adding all yarn.lock files into sha sum.
|
|
||||||
const result = [];
|
|
||||||
findFiles('', 'yarn.lock', result);
|
|
||||||
result.forEach(f => shasum.update(fs.readFileSync(f)));
|
|
||||||
// Add any other command line arguments
|
|
||||||
for (let i = 2; i < process.argv.length; i++) {
|
|
||||||
shasum.update(process.argv[i]);
|
|
||||||
}
|
|
||||||
process.stdout.write(shasum.digest('hex'));
|
|
||||||
@@ -1,54 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
import * as fs from 'fs';
|
|
||||||
import * as path from 'path';
|
|
||||||
import * as crypto from 'crypto';
|
|
||||||
|
|
||||||
const ROOT = path.join(__dirname, '../../../');
|
|
||||||
|
|
||||||
function findFiles(location: string, pattern: string, result: string[]) {
|
|
||||||
const entries = fs.readdirSync(path.join(ROOT, location));
|
|
||||||
|
|
||||||
for (const entry of entries) {
|
|
||||||
const entryPath = `${location}/${entry}`;
|
|
||||||
let stat: fs.Stats;
|
|
||||||
try {
|
|
||||||
stat = fs.statSync(path.join(ROOT, entryPath));
|
|
||||||
} catch (err) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
if (stat.isDirectory()) {
|
|
||||||
findFiles(entryPath, pattern, result);
|
|
||||||
} else {
|
|
||||||
if (stat.isFile() && entry.endsWith(pattern)) {
|
|
||||||
result.push(path.join(ROOT, entryPath));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
const shasum = crypto.createHash('sha1');
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Creating a sha hash of all the files that can cause packages to change/redownload.
|
|
||||||
*/
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'build/.cachesalt')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, '.yarnrc')));
|
|
||||||
shasum.update(fs.readFileSync(path.join(ROOT, 'remote/.yarnrc')));
|
|
||||||
|
|
||||||
// Adding all yarn.lock files into sha sum.
|
|
||||||
const result: string[] = [];
|
|
||||||
findFiles('', 'yarn.lock', result);
|
|
||||||
result.forEach(f => shasum.update(fs.readFileSync(f)));
|
|
||||||
|
|
||||||
// Add any other command line arguments
|
|
||||||
for (let i = 2; i < process.argv.length; i++) {
|
|
||||||
shasum.update(process.argv[i]);
|
|
||||||
}
|
|
||||||
|
|
||||||
process.stdout.write(shasum.digest('hex'));
|
|
||||||
@@ -1,87 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const url = require("url");
|
|
||||||
const azure = require("azure-storage");
|
|
||||||
const mime = require("mime");
|
|
||||||
const cosmos_1 = require("@azure/cosmos");
|
|
||||||
const retry_1 = require("./retry");
|
|
||||||
function log(...args) {
|
|
||||||
console.log(...[`[${new Date().toISOString()}]`, ...args]);
|
|
||||||
}
|
|
||||||
function error(...args) {
|
|
||||||
console.error(...[`[${new Date().toISOString()}]`, ...args]);
|
|
||||||
}
|
|
||||||
if (process.argv.length < 3) {
|
|
||||||
error('Usage: node sync-mooncake.js <quality>');
|
|
||||||
process.exit(-1);
|
|
||||||
}
|
|
||||||
async function sync(commit, quality) {
|
|
||||||
log(`Synchronizing Mooncake assets for ${quality}, ${commit}...`);
|
|
||||||
const client = new cosmos_1.CosmosClient({ endpoint: process.env['AZURE_DOCUMENTDB_ENDPOINT'], key: process.env['AZURE_DOCUMENTDB_MASTERKEY'] });
|
|
||||||
const container = client.database('builds').container(quality);
|
|
||||||
const query = `SELECT TOP 1 * FROM c WHERE c.id = "${commit}"`;
|
|
||||||
const res = await container.items.query(query, {}).fetchAll();
|
|
||||||
if (res.resources.length !== 1) {
|
|
||||||
throw new Error(`No builds found for ${commit}`);
|
|
||||||
}
|
|
||||||
const build = res.resources[0];
|
|
||||||
log(`Found build for ${commit}, with ${build.assets.length} assets`);
|
|
||||||
const storageAccount = process.env['AZURE_STORAGE_ACCOUNT_2'];
|
|
||||||
const blobService = azure.createBlobService(storageAccount, process.env['AZURE_STORAGE_ACCESS_KEY_2'])
|
|
||||||
.withFilter(new azure.ExponentialRetryPolicyFilter(20));
|
|
||||||
const mooncakeBlobService = azure.createBlobService(storageAccount, process.env['MOONCAKE_STORAGE_ACCESS_KEY'], `${storageAccount}.blob.core.chinacloudapi.cn`)
|
|
||||||
.withFilter(new azure.ExponentialRetryPolicyFilter(20));
|
|
||||||
// mooncake is fussy and far away, this is needed!
|
|
||||||
blobService.defaultClientRequestTimeoutInMs = 10 * 60 * 1000;
|
|
||||||
mooncakeBlobService.defaultClientRequestTimeoutInMs = 10 * 60 * 1000;
|
|
||||||
for (const asset of build.assets) {
|
|
||||||
try {
|
|
||||||
const blobPath = url.parse(asset.url).path;
|
|
||||||
if (!blobPath) {
|
|
||||||
throw new Error(`Failed to parse URL: ${asset.url}`);
|
|
||||||
}
|
|
||||||
const blobName = blobPath.replace(/^\/\w+\//, '');
|
|
||||||
log(`Found ${blobName}`);
|
|
||||||
if (asset.mooncakeUrl) {
|
|
||||||
log(` Already in Mooncake ✔️`);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
const readStream = blobService.createReadStream(quality, blobName, undefined);
|
|
||||||
const blobOptions = {
|
|
||||||
contentSettings: {
|
|
||||||
contentType: mime.lookup(blobPath),
|
|
||||||
cacheControl: 'max-age=31536000, public'
|
|
||||||
}
|
|
||||||
};
|
|
||||||
const writeStream = mooncakeBlobService.createWriteStreamToBlockBlob(quality, blobName, blobOptions, undefined);
|
|
||||||
log(` Uploading to Mooncake...`);
|
|
||||||
await new Promise((c, e) => readStream.pipe(writeStream).on('finish', c).on('error', e));
|
|
||||||
log(` Updating build in DB...`);
|
|
||||||
const mooncakeUrl = `${process.env['MOONCAKE_CDN_URL']}${blobPath}`;
|
|
||||||
await retry_1.retry(() => container.scripts.storedProcedure('setAssetMooncakeUrl')
|
|
||||||
.execute('', [commit, asset.platform, asset.type, mooncakeUrl]));
|
|
||||||
log(` Done ✔️`);
|
|
||||||
}
|
|
||||||
catch (err) {
|
|
||||||
error(err);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
log(`All done ✔️`);
|
|
||||||
}
|
|
||||||
function main() {
|
|
||||||
const commit = process.env['BUILD_SOURCEVERSION'];
|
|
||||||
if (!commit) {
|
|
||||||
error('Skipping publish due to missing BUILD_SOURCEVERSION');
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const quality = process.argv[2];
|
|
||||||
sync(commit, quality).catch(err => {
|
|
||||||
error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
main();
|
|
||||||
@@ -9,7 +9,6 @@ import * as url from 'url';
|
|||||||
import * as azure from 'azure-storage';
|
import * as azure from 'azure-storage';
|
||||||
import * as mime from 'mime';
|
import * as mime from 'mime';
|
||||||
import { CosmosClient } from '@azure/cosmos';
|
import { CosmosClient } from '@azure/cosmos';
|
||||||
import { retry } from './retry';
|
|
||||||
|
|
||||||
function log(...args: any[]) {
|
function log(...args: any[]) {
|
||||||
console.log(...[`[${new Date().toISOString()}]`, ...args]);
|
console.log(...[`[${new Date().toISOString()}]`, ...args]);
|
||||||
@@ -100,8 +99,8 @@ async function sync(commit: string, quality: string): Promise<void> {
|
|||||||
|
|
||||||
log(` Updating build in DB...`);
|
log(` Updating build in DB...`);
|
||||||
const mooncakeUrl = `${process.env['MOONCAKE_CDN_URL']}${blobPath}`;
|
const mooncakeUrl = `${process.env['MOONCAKE_CDN_URL']}${blobPath}`;
|
||||||
await retry(() => container.scripts.storedProcedure('setAssetMooncakeUrl')
|
await container.scripts.storedProcedure('setAssetMooncakeUrl')
|
||||||
.execute('', [commit, asset.platform, asset.type, mooncakeUrl]));
|
.execute('', [commit, asset.platform, asset.type, mooncakeUrl]);
|
||||||
|
|
||||||
log(` Done ✔️`);
|
log(` Done ✔️`);
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
steps:
|
steps:
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@3 # {{SQL CARBON EDIT}} update version
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@3 # {{SQL CARBON EDIT}} update version
|
||||||
inputs:
|
inputs:
|
||||||
|
|||||||
@@ -0,0 +1,10 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||||
|
<plist version="1.0">
|
||||||
|
<dict>
|
||||||
|
<key>com.apple.security.cs.allow-unsigned-executable-memory</key>
|
||||||
|
<true/>
|
||||||
|
<key>com.apple.security.cs.disable-library-validation</key>
|
||||||
|
<true/>
|
||||||
|
</dict>
|
||||||
|
</plist>
|
||||||
@@ -1,7 +1,32 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
echo -n $ENABLE_TERRAPIN > .build/terrapin
|
||||||
|
displayName: Prepare compilation cache flags
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: "build/.cachesalt, .build/commit, .build/quality, .build/terrapin"
|
||||||
|
targetfolder: ".build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
platformIndependent: true
|
||||||
|
alias: "Compilation"
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
|
inputs:
|
||||||
|
versionSpec: "1.x"
|
||||||
|
|
||||||
- task: AzureKeyVault@1
|
- task: AzureKeyVault@1
|
||||||
displayName: "Azure Key Vault: Get Secrets"
|
displayName: "Azure Key Vault: Get Secrets"
|
||||||
@@ -9,21 +34,9 @@ steps:
|
|||||||
azureSubscription: "vscode-builds-subscription"
|
azureSubscription: "vscode-builds-subscription"
|
||||||
KeyVaultName: vscode
|
KeyVaultName: vscode
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
path: $(Build.ArtifactStagingDirectory)
|
|
||||||
displayName: Download compilation output
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_ARCH'], 'universal'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
tar -xzf $(Build.ArtifactStagingDirectory)/compilation.tar.gz
|
|
||||||
displayName: Extract compilation output
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_ARCH'], 'universal'))
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
cat << EOF > ~/.netrc
|
cat << EOF > ~/.netrc
|
||||||
machine github.com
|
machine github.com
|
||||||
login vscode
|
login vscode
|
||||||
@@ -42,45 +55,40 @@ steps:
|
|||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
git pull --no-rebase https://github.com/$(VSCODE_MIXIN_REPO).git $(node -p "require('./package.json').distro")
|
git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git"
|
||||||
|
git fetch distro
|
||||||
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
mkdir -p .build
|
npx https://aka.ms/enablesecurefeed standAlone
|
||||||
node build/azure-pipelines/common/computeNodeModulesCacheKey.js $VSCODE_ARCH $ENABLE_TERRAPIN > .build/yarnlockhash
|
displayName: Switch to Terrapin packages
|
||||||
|
timeoutInMinutes: 5
|
||||||
|
condition: and(succeeded(), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
echo -n $(VSCODE_ARCH) > .build/arch
|
||||||
displayName: Prepare yarn cache flags
|
displayName: Prepare yarn cache flags
|
||||||
|
|
||||||
- task: Cache@2
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
inputs:
|
inputs:
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
path: .build/node_modules_cache
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
vstsFeed: "npm-vscode"
|
||||||
displayName: Restore node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
tar -xzf .build/node_modules_cache/cache.tgz
|
npm install -g node-gyp@7.1.0
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
npm install -g node-gyp@latest
|
|
||||||
node-gyp --version
|
node-gyp --version
|
||||||
displayName: Update node-gyp
|
displayName: Update node-gyp
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
|
||||||
npx https://aka.ms/enablesecurefeed standAlone
|
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
|
||||||
displayName: Switch to Terrapin packages
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
export npm_config_arch=$(VSCODE_ARCH)
|
export npm_config_arch=$(VSCODE_ARCH)
|
||||||
export npm_config_node_gyp=$(which node-gyp)
|
export npm_config_node_gyp=$(which node-gyp)
|
||||||
export SDKROOT=/Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
|
export SDKROOT=/Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
|
||||||
|
export CHILD_CONCURRENCY="1"
|
||||||
|
|
||||||
for i in {1..3}; do # try 3 times, for Terrapin
|
for i in {1..3}; do # try 3 times, for Terrapin
|
||||||
yarn --frozen-lockfile && break
|
yarn --frozen-lockfile && break
|
||||||
@@ -90,19 +98,25 @@ steps:
|
|||||||
fi
|
fi
|
||||||
echo "Yarn failed $i, trying again..."
|
echo "Yarn failed $i, trying again..."
|
||||||
done
|
done
|
||||||
env:
|
|
||||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
|
||||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
|
||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
export npm_config_arch=$(VSCODE_ARCH)
|
||||||
mkdir -p .build/node_modules_cache
|
export npm_config_node_gyp=$(which node-gyp)
|
||||||
tar -czf .build/node_modules_cache/cache.tgz --files-from .build/node_modules_list.txt
|
export SDKROOT=/Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
ls /Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/
|
||||||
displayName: Create node_modules archive
|
yarn postinstall
|
||||||
|
displayName: Run postinstall scripts
|
||||||
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -112,21 +126,10 @@ steps:
|
|||||||
export SDKROOT=/Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
|
export SDKROOT=/Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
|
||||||
ls /Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/
|
ls /Applications/Xcode_12.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/
|
||||||
yarn electron-rebuild
|
yarn electron-rebuild
|
||||||
# remove once https://github.com/prebuild/prebuild-install/pull/140 is merged and found in keytar
|
|
||||||
cd ./node_modules/keytar
|
cd ./node_modules/keytar
|
||||||
node-gyp rebuild
|
node-gyp rebuild
|
||||||
displayName: Rebuild native modules for ARM64
|
displayName: Rebuild native modules for ARM64
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'arm64'))
|
condition: eq(variables['VSCODE_ARCH'], 'arm64')
|
||||||
|
|
||||||
- download: current
|
|
||||||
artifact: vscode-darwin-x64
|
|
||||||
displayName: Download x64 artifact
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'universal'))
|
|
||||||
|
|
||||||
- download: current
|
|
||||||
artifact: vscode-darwin-arm64
|
|
||||||
displayName: Download arm64 artifact
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'universal'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -138,7 +141,6 @@ steps:
|
|||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
yarn gulp vscode-darwin-$(VSCODE_ARCH)-min-ci
|
yarn gulp vscode-darwin-$(VSCODE_ARCH)-min-ci
|
||||||
displayName: Build
|
displayName: Build
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_ARCH'], 'universal'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -146,23 +148,14 @@ steps:
|
|||||||
yarn gulp vscode-reh-darwin-min-ci
|
yarn gulp vscode-reh-darwin-min-ci
|
||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
yarn gulp vscode-reh-web-darwin-min-ci
|
yarn gulp vscode-reh-web-darwin-min-ci
|
||||||
displayName: Build Server
|
displayName: Build reh
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
unzip $(Pipeline.Workspace)/vscode-darwin-x64/VSCode-darwin-x64.zip -d $(agent.builddirectory)/vscode-x64
|
yarn electron $(VSCODE_ARCH)
|
||||||
unzip $(Pipeline.Workspace)/vscode-darwin-arm64/VSCode-darwin-arm64.zip -d $(agent.builddirectory)/vscode-arm64
|
displayName: Download Electron
|
||||||
DEBUG=* node build/darwin/create-universal-app.js
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
displayName: Create Universal App
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'universal'))
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
|
||||||
yarn npm-run-all -lp "electron $(VSCODE_ARCH)" "playwright-install"
|
|
||||||
displayName: Download Electron and Playwright
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_ARCH'], 'universal'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -174,26 +167,17 @@ steps:
|
|||||||
security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k pwd $(agent.tempdirectory)/buildagent.keychain
|
security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k pwd $(agent.tempdirectory)/buildagent.keychain
|
||||||
VSCODE_ARCH="$(VSCODE_ARCH)" DEBUG=electron-osx-sign* node build/darwin/sign.js
|
VSCODE_ARCH="$(VSCODE_ARCH)" DEBUG=electron-osx-sign* node build/darwin/sign.js
|
||||||
displayName: Set Hardened Entitlements
|
displayName: Set Hardened Entitlements
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
./scripts/test.sh --build --tfs "Unit Tests"
|
./scripts/test.sh --build --tfs "Unit Tests"
|
||||||
displayName: Run unit tests (Electron)
|
displayName: Run unit tests (Electron)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
yarn test-browser --build --browser chromium --browser webkit --browser firefox --tfs "Browser Unit Tests"
|
yarn test-browser --build --browser chromium --browser webkit --browser firefox --tfs "Browser Unit Tests"
|
||||||
displayName: Run unit tests (Browser)
|
displayName: Run unit tests (Browser)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
yarn --cwd test/integration/browser compile
|
|
||||||
displayName: Compile integration tests
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
@@ -207,15 +191,13 @@ steps:
|
|||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-darwin" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-darwin" \
|
||||||
./scripts/test-integration.sh --build --tfs "Integration Tests"
|
./scripts/test-integration.sh --build --tfs "Integration Tests"
|
||||||
displayName: Run integration tests (Electron)
|
displayName: Run integration tests (Electron)
|
||||||
timeoutInMinutes: 10
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-darwin" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-darwin" \
|
||||||
./resources/server/test/test-web-integration.sh --browser webkit
|
./resources/server/test/test-web-integration.sh --browser webkit
|
||||||
displayName: Run integration tests (Browser)
|
displayName: Run integration tests (Browser)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
@@ -226,39 +208,22 @@ steps:
|
|||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-darwin" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-darwin" \
|
||||||
./resources/server/test/test-remote-integration.sh
|
./resources/server/test/test-remote-integration.sh
|
||||||
displayName: Run remote integration tests (Electron)
|
displayName: Run remote integration tests (Electron)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
yarn --cwd test/smoke compile
|
|
||||||
displayName: Compile smoke tests
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
APP_ROOT=$(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH)
|
APP_ROOT=$(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH)
|
||||||
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
||||||
yarn smoketest-no-compile --build "$APP_ROOT/$APP_NAME"
|
yarn smoketest --build "$APP_ROOT/$APP_NAME"
|
||||||
timeoutInMinutes: 5
|
continueOnError: true
|
||||||
displayName: Run smoke tests (Electron)
|
displayName: Run smoke tests (Electron)
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
APP_ROOT=$(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH)
|
|
||||||
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-darwin" \
|
|
||||||
yarn smoketest-no-compile --build "$APP_ROOT/$APP_NAME" --remote
|
|
||||||
timeoutInMinutes: 5
|
|
||||||
displayName: Run smoke tests (Remote)
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-darwin" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-darwin" \
|
||||||
yarn smoketest-no-compile --web --headless
|
yarn smoketest --web --headless
|
||||||
timeoutInMinutes: 5
|
continueOnError: true
|
||||||
displayName: Run smoke tests (Browser)
|
displayName: Run smoke tests (Browser)
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
@@ -275,13 +240,12 @@ steps:
|
|||||||
inputs:
|
inputs:
|
||||||
testResultsFiles: "*-results.xml"
|
testResultsFiles: "*-results.xml"
|
||||||
searchFolder: "$(Build.ArtifactStagingDirectory)/test-results"
|
searchFolder: "$(Build.ArtifactStagingDirectory)/test-results"
|
||||||
condition: and(succeededOrFailed(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: succeededOrFailed()
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
pushd $(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH) && zip -r -X -y $(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH).zip * && popd
|
pushd $(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH) && zip -r -X -y $(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH).zip * && popd
|
||||||
displayName: Archive build
|
displayName: Archive build
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
||||||
inputs:
|
inputs:
|
||||||
@@ -306,12 +270,10 @@ steps:
|
|||||||
]
|
]
|
||||||
SessionTimeout: 60
|
SessionTimeout: 60
|
||||||
displayName: Codesign
|
displayName: Codesign
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
zip -d $(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH).zip "*.pkg"
|
zip -d $(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH).zip "*.pkg"
|
||||||
displayName: Clean
|
displayName: Clean Archive
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
APP_ROOT=$(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH)
|
APP_ROOT=$(agent.builddirectory)/VSCode-darwin-$(VSCODE_ARCH)
|
||||||
@@ -319,7 +281,6 @@ steps:
|
|||||||
BUNDLE_IDENTIFIER=$(node -p "require(\"$APP_ROOT/$APP_NAME/Contents/Resources/app/product.json\").darwinBundleIdentifier")
|
BUNDLE_IDENTIFIER=$(node -p "require(\"$APP_ROOT/$APP_NAME/Contents/Resources/app/product.json\").darwinBundleIdentifier")
|
||||||
echo "##vso[task.setvariable variable=BundleIdentifier]$BUNDLE_IDENTIFIER"
|
echo "##vso[task.setvariable variable=BundleIdentifier]$BUNDLE_IDENTIFIER"
|
||||||
displayName: Export bundle identifier
|
displayName: Export bundle identifier
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
||||||
inputs:
|
inputs:
|
||||||
@@ -344,7 +305,6 @@ steps:
|
|||||||
]
|
]
|
||||||
SessionTimeout: 60
|
SessionTimeout: 60
|
||||||
displayName: Notarization
|
displayName: Notarization
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -352,7 +312,7 @@ steps:
|
|||||||
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
||||||
"$APP_ROOT/$APP_NAME/Contents/Resources/app/bin/code" --export-default-configuration=.build
|
"$APP_ROOT/$APP_NAME/Contents/Resources/app/bin/code" --export-default-configuration=.build
|
||||||
displayName: Verify start after signing (export configuration)
|
displayName: Verify start after signing (export configuration)
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_ARCH'], 'arm64'), ne(variables['VSCODE_PUBLISH'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -363,29 +323,13 @@ steps:
|
|||||||
VSCODE_ARCH="$(VSCODE_ARCH)" \
|
VSCODE_ARCH="$(VSCODE_ARCH)" \
|
||||||
./build/azure-pipelines/darwin/publish.sh
|
./build/azure-pipelines/darwin/publish.sh
|
||||||
displayName: Publish
|
displayName: Publish
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/VSCode-darwin-$(VSCODE_ARCH).zip
|
|
||||||
artifact: vscode-darwin-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/vscode-server-darwin.zip
|
|
||||||
artifact: vscode-server-darwin-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish server archive
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/vscode-server-darwin-web.zip
|
|
||||||
artifact: vscode-server-darwin-$(VSCODE_ARCH)-web
|
|
||||||
displayName: Publish web server archive
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
AZURE_STORAGE_ACCESS_KEY="$(ticino-storage-key)" \
|
AZURE_STORAGE_ACCESS_KEY="$(ticino-storage-key)" \
|
||||||
VSCODE_ARCH="$(VSCODE_ARCH)" \
|
VSCODE_ARCH="$(VSCODE_ARCH)" \
|
||||||
yarn gulp upload-vscode-configuration
|
yarn gulp upload-vscode-configuration
|
||||||
displayName: Upload configuration (for Bing settings search)
|
displayName: Upload configuration (for Bing settings search)
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), ne(variables['VSCODE_PUBLISH'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'))
|
||||||
continueOnError: true
|
continueOnError: true
|
||||||
|
|
||||||
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
||||||
|
|||||||
@@ -5,7 +5,6 @@ set -e
|
|||||||
case $VSCODE_ARCH in
|
case $VSCODE_ARCH in
|
||||||
x64) ASSET_ID="darwin" ;;
|
x64) ASSET_ID="darwin" ;;
|
||||||
arm64) ASSET_ID="darwin-arm64" ;;
|
arm64) ASSET_ID="darwin-arm64" ;;
|
||||||
universal) ASSET_ID="darwin-universal" ;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# publish the build
|
# publish the build
|
||||||
|
|||||||
@@ -5,15 +5,26 @@ steps:
|
|||||||
certSecureFile: 'osx_signing_key.p12'
|
certSecureFile: 'osx_signing_key.p12'
|
||||||
condition: eq(variables['signed'], true)
|
condition: eq(variables['signed'], true)
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
displayName: Prepare cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
displayName: Restore Cache - Compiled Files
|
||||||
inputs:
|
inputs:
|
||||||
artifact: Compilation
|
keyfile: 'build/.cachesalt, .build/commit, .build/quality'
|
||||||
displayName: Download compilation output
|
targetfolder: '.build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min'
|
||||||
|
vstsFeed: 'BuildCache'
|
||||||
|
platformIndependent: true
|
||||||
|
alias: 'Compilation'
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
tar -xzf $(Pipeline.Workspace)/compilation.tar.gz
|
exit 1
|
||||||
displayName: Extract compilation output
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
@@ -50,23 +61,12 @@ steps:
|
|||||||
git merge $(node -p "require('./package.json').distro")
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- script: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
mkdir -p .build
|
|
||||||
node build/azure-pipelines/common/sql-computeNodeModulesCacheKey.js > .build/yarnlockhash
|
|
||||||
displayName: Prepare yarn cache key
|
|
||||||
|
|
||||||
- task: Cache@2
|
|
||||||
displayName: Restore Cache - Node Modules
|
displayName: Restore Cache - Node Modules
|
||||||
inputs:
|
inputs:
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
path: .build/node_modules_cache
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
vstsFeed: 'BuildCache'
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf .build/node_modules_cache/cache.tgz
|
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules archive
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -74,21 +74,21 @@ steps:
|
|||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: $(github-distro-mixin-password)
|
GITHUB_TOKEN: $(github-distro-mixin-password)
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
set -e
|
displayName: Save Cache - Node Modules
|
||||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
inputs:
|
||||||
mkdir -p .build/node_modules_cache
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
tar -czf .build/node_modules_cache/cache.tgz --files-from .build/node_modules_list.txt
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
vstsFeed: 'BuildCache'
|
||||||
displayName: Create node_modules archive
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
yarn postinstall
|
yarn postinstall
|
||||||
displayName: Run postinstall scripts
|
displayName: Run postinstall scripts
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -122,16 +122,11 @@ steps:
|
|||||||
displayName: Run integration tests (Electron)
|
displayName: Run integration tests (Electron)
|
||||||
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
yarn gulp compile-extensions
|
|
||||||
displayName: Compile Extensions
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
APP_ROOT=$(agent.builddirectory)/azuredatastudio-darwin-x64
|
APP_ROOT=$(agent.builddirectory)/azuredatastudio-darwin-x64
|
||||||
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
APP_NAME="`ls $APP_ROOT | head -n 1`"
|
||||||
yarn smoketest --build "$APP_ROOT/$APP_NAME" --screenshots "$(build.artifactstagingdirectory)/smokeshots" --log "$(build.artifactstagingdirectory)/logs/darwin/smoke.log" --extensionsDir "$(build.sourcesdirectory)/extensions"
|
yarn smoketest --build "$APP_ROOT/$APP_NAME" --screenshots "$(build.artifactstagingdirectory)/smokeshots" --log "$(build.artifactstagingdirectory)/logs/darwin/smoke.log"
|
||||||
displayName: Run smoke tests (Electron)
|
displayName: Run smoke tests (Electron)
|
||||||
continueOnError: true
|
continueOnError: true
|
||||||
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
pool:
|
pool:
|
||||||
vmImage: 'Ubuntu-18.04'
|
vmImage: 'Ubuntu-16.04'
|
||||||
|
|
||||||
trigger:
|
trigger:
|
||||||
branches:
|
branches:
|
||||||
@@ -11,7 +11,7 @@ pr:
|
|||||||
steps:
|
steps:
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: AzureKeyVault@1
|
- task: AzureKeyVault@1
|
||||||
displayName: 'Azure Key Vault: Get Secrets'
|
displayName: 'Azure Key Vault: Get Secrets'
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
#Download base image ubuntu 18.04
|
#Download base image ubuntu 16.04
|
||||||
FROM ubuntu:18.04
|
FROM ubuntu:16.04
|
||||||
|
|
||||||
# Update Software repository
|
# Update Software repository
|
||||||
RUN apt-get update
|
RUN apt-get update
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ SERVER_BUILD_NAME="azuredatastudio-server-$PLATFORM_LINUX"
|
|||||||
|
|
||||||
# create docker
|
# create docker
|
||||||
mkdir -p $REPO/.build/docker
|
mkdir -p $REPO/.build/docker
|
||||||
docker build -t azuredatastudio-server -f $REPO/build/azure-pipelines/docker/Dockerfile $ROOT/$SERVER_BUILD_NAME-web
|
docker build -t azuredatastudio-server -f $REPO/build/azure-pipelines/docker/Dockerfile $ROOT/$SERVER_BUILD_NAME
|
||||||
docker save azuredatastudio-server | gzip > $REPO/.build/docker/azuredatastudio-server-docker.tar.gz
|
docker save azuredatastudio-server | gzip > $REPO/.build/docker/azuredatastudio-server-docker.tar.gz
|
||||||
|
|
||||||
node build/azure-pipelines/common/copyArtifacts.js
|
node build/azure-pipelines/common/copyArtifacts.js
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ steps:
|
|||||||
set -e
|
set -e
|
||||||
for f in $(Build.SourcesDirectory)/.build/drop/linux/server/*.tar.gz
|
for f in $(Build.SourcesDirectory)/.build/drop/linux/server/*.tar.gz
|
||||||
do
|
do
|
||||||
tar -C $(Build.SourcesDirectory)/../ -zxvf $f
|
tar -C $(agent.builddirectory) -zxvf $f
|
||||||
rm $f
|
rm $f
|
||||||
done
|
done
|
||||||
displayName: Unzip artifacts
|
displayName: Unzip artifacts
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ pr:
|
|||||||
steps:
|
steps:
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: AzureKeyVault@1
|
- task: AzureKeyVault@1
|
||||||
displayName: "Azure Key Vault: Get Secrets"
|
displayName: "Azure Key Vault: Get Secrets"
|
||||||
|
|||||||
@@ -1,17 +1,17 @@
|
|||||||
#Download base image ubuntu 18.04
|
#Download base image ubuntu 16.04
|
||||||
FROM ubuntu:18.04
|
FROM ubuntu:16.04
|
||||||
|
|
||||||
# Update Software repository
|
# Update Software repository
|
||||||
RUN apt-get update && apt-get upgrade -y
|
RUN apt-get update && apt-get upgrade -y
|
||||||
|
|
||||||
RUN apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 \
|
RUN apt-get install -y libxkbfile-dev pkg-config libsecret-1-dev libxss1 dbus xvfb libgtk-3-0 \
|
||||||
libkrb5-dev git apt-transport-https ca-certificates curl gnupg-agent software-properties-common \
|
libkrb5-dev git apt-transport-https ca-certificates curl gnupg-agent software-properties-common \
|
||||||
libnss3 libasound2 make gcc libx11-dev fakeroot rpm libgconf-2-4 libunwind8 g++-4.9
|
libnss3 libasound2 make gcc libx11-dev fakeroot rpm libgconf-2-4 libunwind8 g++-4.8
|
||||||
|
|
||||||
RUN rm /usr/bin/gcc
|
RUN rm /usr/bin/gcc
|
||||||
RUN rm /usr/bin/g++
|
RUN rm /usr/bin/g++
|
||||||
RUN ln -s /usr/bin/gcc-4.9 /usr/bin/gcc
|
RUN ln -s /usr/bin/gcc-4.8 /usr/bin/gcc
|
||||||
RUN ln -s /usr/bin/g++-4.9 /usr/bin/g++
|
RUN ln -s /usr/bin/g++-4.8 /usr/bin/g++
|
||||||
|
|
||||||
#docker
|
#docker
|
||||||
RUN curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -
|
RUN curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ SERVER_BUILD_NAME="vscode-server-$PLATFORM_LINUX-web"
|
|||||||
SERVER_TARBALL_FILENAME="vscode-server-$PLATFORM_LINUX-web.tar.gz"
|
SERVER_TARBALL_FILENAME="vscode-server-$PLATFORM_LINUX-web.tar.gz"
|
||||||
SERVER_TARBALL_PATH="$ROOT/$SERVER_TARBALL_FILENAME"
|
SERVER_TARBALL_PATH="$ROOT/$SERVER_TARBALL_FILENAME"
|
||||||
|
|
||||||
rm -rf $ROOT/vscode-server-*-web.tar.*
|
rm -rf $ROOT/vscode-server-*.tar.*
|
||||||
(cd $ROOT && mv $LEGACY_SERVER_BUILD_NAME $SERVER_BUILD_NAME && tar --owner=0 --group=0 -czf $SERVER_TARBALL_PATH $SERVER_BUILD_NAME)
|
(cd $ROOT && mv $LEGACY_SERVER_BUILD_NAME $SERVER_BUILD_NAME && tar --owner=0 --group=0 -czf $SERVER_TARBALL_PATH $SERVER_BUILD_NAME)
|
||||||
|
|
||||||
node build/azure-pipelines/common/createAsset.js "server-$PLATFORM_LINUX-web" archive-unsigned "$SERVER_TARBALL_FILENAME" "$SERVER_TARBALL_PATH"
|
node build/azure-pipelines/common/createAsset.js "server-$PLATFORM_LINUX-web" archive-unsigned "$SERVER_TARBALL_FILENAME" "$SERVER_TARBALL_PATH"
|
||||||
|
|||||||
@@ -10,21 +10,16 @@ steps:
|
|||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@3
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@3
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "1.x"
|
versionSpec: "1.x"
|
||||||
|
|
||||||
- script: |
|
|
||||||
mkdir -p .build
|
|
||||||
node build/azure-pipelines/common/computeNodeModulesCacheKey.js > .build/yarnlockhash
|
|
||||||
displayName: Prepare yarn cache flags
|
|
||||||
|
|
||||||
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
displayName: Restore Cache - Node Modules # {{SQL CARBON EDIT}}
|
displayName: Restore Cache - Node Modules # {{SQL CARBON EDIT}}
|
||||||
inputs:
|
inputs:
|
||||||
keyfile: ".yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
keyfile: "build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock"
|
||||||
targetfolder: "**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules"
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules"
|
||||||
vstsFeed: "npm-cache" # {{SQL CARBON EDIT}} update build cache
|
vstsFeed: "npm-cache" # {{SQL CARBON EDIT}} update build cache
|
||||||
|
|
||||||
@@ -36,7 +31,7 @@ steps:
|
|||||||
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
displayName: Save Cache - Node Modules # {{SQL CARBON EDIT}}
|
displayName: Save Cache - Node Modules # {{SQL CARBON EDIT}}
|
||||||
inputs:
|
inputs:
|
||||||
keyfile: ".yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
keyfile: "build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock"
|
||||||
targetfolder: "**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules"
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules"
|
||||||
vstsFeed: "npm-cache" # {{SQL CARBON EDIT}} update build cache
|
vstsFeed: "npm-cache" # {{SQL CARBON EDIT}} update build cache
|
||||||
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|||||||
@@ -14,22 +14,13 @@ TARBALL_PATH="$REPO/.build/linux/archive/$TARBALL_FILENAME"
|
|||||||
rm -rf $ROOT/code-*.tar.*
|
rm -rf $ROOT/code-*.tar.*
|
||||||
(cd $ROOT && tar -czf $TARBALL_PATH $BUILDNAME)
|
(cd $ROOT && tar -czf $TARBALL_PATH $BUILDNAME)
|
||||||
|
|
||||||
# # Publish Remote Extension Host
|
# Publish Remote Extension Host
|
||||||
# LEGACY_SERVER_BUILD_NAME="azuredatastudio-reh-$PLATFORM_LINUX"
|
LEGACY_SERVER_BUILD_NAME="azuredatastudio-reh-$PLATFORM_LINUX"
|
||||||
# SERVER_BUILD_NAME="azuredatastudio-server-$PLATFORM_LINUX"
|
SERVER_BUILD_NAME="azuredatastudio-server-$PLATFORM_LINUX"
|
||||||
# SERVER_TARBALL_FILENAME="azuredatastudio-server-$PLATFORM_LINUX.tar.gz"
|
SERVER_TARBALL_FILENAME="azuredatastudio-server-$PLATFORM_LINUX.tar.gz"
|
||||||
# SERVER_TARBALL_PATH="$REPO/.build/linux/server/$SERVER_TARBALL_FILENAME"
|
SERVER_TARBALL_PATH="$REPO/.build/linux/server/$SERVER_TARBALL_FILENAME"
|
||||||
|
|
||||||
# rm -rf $ROOT/azuredatastudio-server-*.tar.*
|
|
||||||
# (cd $ROOT && mv $LEGACY_SERVER_BUILD_NAME $SERVER_BUILD_NAME && tar --owner=0 --group=0 -czf $SERVER_TARBALL_PATH $SERVER_BUILD_NAME)
|
|
||||||
|
|
||||||
# Publish Remote Extension Host (Web)
|
|
||||||
LEGACY_SERVER_BUILD_NAME_WEB="azuredatastudio-reh-web-$PLATFORM_LINUX"
|
|
||||||
SERVER_BUILD_NAME_WEB="azuredatastudio-server-$PLATFORM_LINUX-web"
|
|
||||||
SERVER_TARBALL_FILENAME_WEB="azuredatastudio-server-$PLATFORM_LINUX-web.tar.gz"
|
|
||||||
SERVER_TARBALL_PATH_WEB="$REPO/.build/linux/server/$SERVER_TARBALL_FILENAME_WEB"
|
|
||||||
|
|
||||||
rm -rf $ROOT/azuredatastudio-server-*.tar.*
|
rm -rf $ROOT/azuredatastudio-server-*.tar.*
|
||||||
(cd $ROOT && mv vscode-reh-web-linux-x64 $SERVER_BUILD_NAME_WEB && tar --owner=0 --group=0 -czf $SERVER_TARBALL_PATH_WEB $SERVER_BUILD_NAME_WEB)
|
(cd $ROOT && mv $LEGACY_SERVER_BUILD_NAME $SERVER_BUILD_NAME && tar --owner=0 --group=0 -czf $SERVER_TARBALL_PATH $SERVER_BUILD_NAME)
|
||||||
|
|
||||||
node build/azure-pipelines/common/copyArtifacts.js
|
node build/azure-pipelines/common/copyArtifacts.js
|
||||||
|
|||||||
@@ -1,7 +1,28 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
echo -n $ENABLE_TERRAPIN > .build/terrapin
|
||||||
|
displayName: Prepare compilation cache flags
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: "build/.cachesalt, .build/commit, .build/quality, .build/terrapin"
|
||||||
|
targetfolder: ".build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
platformIndependent: true
|
||||||
|
alias: "Compilation"
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
@@ -13,17 +34,6 @@ steps:
|
|||||||
azureSubscription: "vscode-builds-subscription"
|
azureSubscription: "vscode-builds-subscription"
|
||||||
KeyVaultName: vscode
|
KeyVaultName: vscode
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
path: $(Build.ArtifactStagingDirectory)
|
|
||||||
displayName: Download compilation output
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf $(Build.ArtifactStagingDirectory)/compilation.tar.gz
|
|
||||||
displayName: Extract compilation output
|
|
||||||
|
|
||||||
- task: Docker@1
|
- task: Docker@1
|
||||||
displayName: "Pull image"
|
displayName: "Pull image"
|
||||||
inputs:
|
inputs:
|
||||||
@@ -35,6 +45,7 @@ steps:
|
|||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
cat << EOF > ~/.netrc
|
cat << EOF > ~/.netrc
|
||||||
machine github.com
|
machine github.com
|
||||||
login vscode
|
login vscode
|
||||||
@@ -47,35 +58,30 @@ steps:
|
|||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
git pull --no-rebase https://github.com/$(VSCODE_MIXIN_REPO).git $(node -p "require('./package.json').distro")
|
git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git"
|
||||||
|
git fetch distro
|
||||||
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
mkdir -p .build
|
npx https://aka.ms/enablesecurefeed standAlone
|
||||||
node build/azure-pipelines/common/computeNodeModulesCacheKey.js "alpine" $ENABLE_TERRAPIN > .build/yarnlockhash
|
displayName: Switch to Terrapin packages
|
||||||
|
timeoutInMinutes: 5
|
||||||
|
condition: and(succeeded(), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
echo -n "alpine" > .build/arch
|
||||||
displayName: Prepare yarn cache flags
|
displayName: Prepare yarn cache flags
|
||||||
|
|
||||||
- task: Cache@2
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
inputs:
|
inputs:
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
path: .build/node_modules_cache
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
vstsFeed: "npm-vscode"
|
||||||
displayName: Restore node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf .build/node_modules_cache/cache.tgz
|
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
npx https://aka.ms/enablesecurefeed standAlone
|
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
|
||||||
displayName: Switch to Terrapin packages
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
|
export CHILD_CONCURRENCY="1"
|
||||||
for i in {1..3}; do # try 3 times, for Terrapin
|
for i in {1..3}; do # try 3 times, for Terrapin
|
||||||
yarn --frozen-lockfile && break
|
yarn --frozen-lockfile && break
|
||||||
if [ $i -eq 3 ]; then
|
if [ $i -eq 3 ]; then
|
||||||
@@ -84,19 +90,21 @@ steps:
|
|||||||
fi
|
fi
|
||||||
echo "Yarn failed $i, trying again..."
|
echo "Yarn failed $i, trying again..."
|
||||||
done
|
done
|
||||||
env:
|
|
||||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
|
||||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
|
||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
yarn postinstall
|
||||||
mkdir -p .build/node_modules_cache
|
displayName: Run postinstall scripts
|
||||||
tar -czf .build/node_modules_cache/cache.tgz --files-from .build/node_modules_list.txt
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Create node_modules archive
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -105,7 +113,7 @@ steps:
|
|||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
docker run -e VSCODE_QUALITY -v $(pwd):/root/vscode -v ~/.netrc:/root/.netrc vscodehub.azurecr.io/vscode-linux-build-agent:alpine /root/vscode/build/azure-pipelines/linux/alpine/install-dependencies.sh
|
docker run -e VSCODE_QUALITY -e CHILD_CONCURRENCY=1 -v $(pwd):/root/vscode -v ~/.netrc:/root/.netrc vscodehub.azurecr.io/vscode-linux-build-agent:alpine /root/vscode/build/azure-pipelines/linux/alpine/install-dependencies.sh
|
||||||
displayName: Prebuild
|
displayName: Prebuild
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
@@ -121,17 +129,6 @@ steps:
|
|||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
./build/azure-pipelines/linux/alpine/publish.sh
|
./build/azure-pipelines/linux/alpine/publish.sh
|
||||||
displayName: Publish
|
displayName: Publish
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/vscode-server-linux-alpine.tar.gz
|
|
||||||
artifact: vscode-server-linux-alpine
|
|
||||||
displayName: Publish server archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/vscode-server-linux-alpine-web.tar.gz
|
|
||||||
artifact: vscode-server-linux-alpine-web
|
|
||||||
displayName: Publish web server archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
||||||
displayName: "Component Detection"
|
displayName: "Component Detection"
|
||||||
|
|||||||
@@ -1,7 +1,28 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
echo -n $ENABLE_TERRAPIN > .build/terrapin
|
||||||
|
displayName: Prepare compilation cache flags
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: "build/.cachesalt, .build/commit, .build/quality, .build/terrapin"
|
||||||
|
targetfolder: ".build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
platformIndependent: true
|
||||||
|
alias: "Compilation"
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
@@ -13,17 +34,6 @@ steps:
|
|||||||
azureSubscription: "vscode-builds-subscription"
|
azureSubscription: "vscode-builds-subscription"
|
||||||
KeyVaultName: vscode
|
KeyVaultName: vscode
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
path: $(Build.ArtifactStagingDirectory)
|
|
||||||
displayName: Download compilation output
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf $(Build.ArtifactStagingDirectory)/compilation.tar.gz
|
|
||||||
displayName: Extract compilation output
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
cat << EOF > ~/.netrc
|
cat << EOF > ~/.netrc
|
||||||
@@ -38,56 +48,31 @@ steps:
|
|||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
git pull --no-rebase https://github.com/$(VSCODE_MIXIN_REPO).git $(node -p "require('./package.json').distro")
|
git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git"
|
||||||
|
git fetch distro
|
||||||
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
mkdir -p .build
|
npx https://aka.ms/enablesecurefeed standAlone
|
||||||
node build/azure-pipelines/common/computeNodeModulesCacheKey.js $VSCODE_ARCH $ENABLE_TERRAPIN > .build/yarnlockhash
|
displayName: Switch to Terrapin packages
|
||||||
|
timeoutInMinutes: 5
|
||||||
|
condition: and(succeeded(), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
echo -n $(VSCODE_ARCH) > .build/arch
|
||||||
displayName: Prepare yarn cache flags
|
displayName: Prepare yarn cache flags
|
||||||
|
|
||||||
- task: Cache@2
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
inputs:
|
inputs:
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
path: .build/node_modules_cache
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
vstsFeed: "npm-vscode"
|
||||||
displayName: Restore node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf .build/node_modules_cache/cache.tgz
|
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
npm install -g node-gyp@latest
|
|
||||||
node-gyp --version
|
|
||||||
displayName: Update node-gyp
|
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), eq(variables['VSCODE_ARCH'], 'x64'))
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
npx https://aka.ms/enablesecurefeed standAlone
|
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
|
||||||
displayName: Switch to Terrapin packages
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
export npm_config_arch=$(NPM_ARCH)
|
export npm_config_arch=$(NPM_ARCH)
|
||||||
export npm_config_build_from_source=true
|
export CHILD_CONCURRENCY="1"
|
||||||
|
|
||||||
if [ -z "$CC" ] || [ -z "$CXX" ]; then
|
|
||||||
export CC=$(which gcc-5)
|
|
||||||
export CXX=$(which g++-5)
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$VSCODE_ARCH" == "x64" ]; then
|
|
||||||
export VSCODE_REMOTE_CC=$(which gcc-4.8)
|
|
||||||
export VSCODE_REMOTE_CXX=$(which g++-4.8)
|
|
||||||
export VSCODE_REMOTE_NODE_GYP=$(which node-gyp)
|
|
||||||
fi
|
|
||||||
|
|
||||||
for i in {1..3}; do # try 3 times, for Terrapin
|
for i in {1..3}; do # try 3 times, for Terrapin
|
||||||
yarn --frozen-lockfile && break
|
yarn --frozen-lockfile && break
|
||||||
if [ $i -eq 3 ]; then
|
if [ $i -eq 3 ]; then
|
||||||
@@ -96,23 +81,21 @@ steps:
|
|||||||
fi
|
fi
|
||||||
echo "Yarn failed $i, trying again..."
|
echo "Yarn failed $i, trying again..."
|
||||||
done
|
done
|
||||||
|
|
||||||
# remove once https://github.com/prebuild/prebuild-install/pull/140 is merged and found in keytar
|
|
||||||
cd ./node_modules/keytar
|
|
||||||
npx node-gyp rebuild
|
|
||||||
env:
|
|
||||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
|
||||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
|
||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
yarn postinstall
|
||||||
mkdir -p .build/node_modules_cache
|
displayName: Run postinstall scripts
|
||||||
tar -czf .build/node_modules_cache/cache.tgz --files-from .build/node_modules_list.txt
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Create node_modules archive
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -123,41 +106,28 @@ steps:
|
|||||||
set -e
|
set -e
|
||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
yarn gulp vscode-linux-$(VSCODE_ARCH)-min-ci
|
yarn gulp vscode-linux-$(VSCODE_ARCH)-min-ci
|
||||||
displayName: Build
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
yarn gulp vscode-reh-linux-$(VSCODE_ARCH)-min-ci
|
yarn gulp vscode-reh-linux-$(VSCODE_ARCH)-min-ci
|
||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
yarn gulp vscode-reh-web-linux-$(VSCODE_ARCH)-min-ci
|
yarn gulp vscode-reh-web-linux-$(VSCODE_ARCH)-min-ci
|
||||||
displayName: Build Server
|
displayName: Build
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
service xvfb start
|
||||||
yarn npm-run-all -lp "electron $(VSCODE_ARCH)" "playwright-install"
|
displayName: Start xvfb
|
||||||
displayName: Download Electron and Playwright
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
DISPLAY=:10 ./scripts/test.sh --build --tfs "Unit Tests"
|
DISPLAY=:10 ./scripts/test.sh --build --tfs "Unit Tests"
|
||||||
displayName: Run unit tests (Electron)
|
displayName: Run unit tests (Electron)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
DISPLAY=:10 yarn test-browser --build --browser chromium --tfs "Browser Unit Tests"
|
DISPLAY=:10 yarn test-browser --build --browser chromium --tfs "Browser Unit Tests"
|
||||||
displayName: Run unit tests (Browser)
|
displayName: Run unit tests (Browser)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
yarn --cwd test/integration/browser compile
|
|
||||||
displayName: Compile integration tests
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
@@ -167,12 +137,10 @@ steps:
|
|||||||
set -e
|
set -e
|
||||||
APP_ROOT=$(agent.builddirectory)/VSCode-linux-$(VSCODE_ARCH)
|
APP_ROOT=$(agent.builddirectory)/VSCode-linux-$(VSCODE_ARCH)
|
||||||
APP_NAME=$(node -p "require(\"$APP_ROOT/resources/app/product.json\").applicationName")
|
APP_NAME=$(node -p "require(\"$APP_ROOT/resources/app/product.json\").applicationName")
|
||||||
INTEGRATION_TEST_APP_NAME="$APP_NAME" \
|
|
||||||
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-linux-$(VSCODE_ARCH)" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-linux-$(VSCODE_ARCH)" \
|
||||||
DISPLAY=:10 ./scripts/test-integration.sh --build --tfs "Integration Tests"
|
DISPLAY=:10 ./scripts/test-integration.sh --build --tfs "Integration Tests"
|
||||||
displayName: Run integration tests (Electron)
|
displayName: Run integration tests (Electron)
|
||||||
timeoutInMinutes: 10
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
@@ -180,19 +148,16 @@ steps:
|
|||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-linux-$(VSCODE_ARCH)" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-web-linux-$(VSCODE_ARCH)" \
|
||||||
DISPLAY=:10 ./resources/server/test/test-web-integration.sh --browser chromium
|
DISPLAY=:10 ./resources/server/test/test-web-integration.sh --browser chromium
|
||||||
displayName: Run integration tests (Browser)
|
displayName: Run integration tests (Browser)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
APP_ROOT=$(agent.builddirectory)/VSCode-linux-$(VSCODE_ARCH)
|
APP_ROOT=$(agent.builddirectory)/VSCode-linux-$(VSCODE_ARCH)
|
||||||
APP_NAME=$(node -p "require(\"$APP_ROOT/resources/app/product.json\").applicationName")
|
APP_NAME=$(node -p "require(\"$APP_ROOT/resources/app/product.json\").applicationName")
|
||||||
INTEGRATION_TEST_APP_NAME="$APP_NAME" \
|
|
||||||
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-linux-$(VSCODE_ARCH)" \
|
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/vscode-reh-linux-$(VSCODE_ARCH)" \
|
||||||
DISPLAY=:10 ./resources/server/test/test-remote-integration.sh
|
DISPLAY=:10 ./resources/server/test/test-remote-integration.sh
|
||||||
displayName: Run remote integration tests (Electron)
|
displayName: Run remote integration tests (Electron)
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), eq(variables['VSCODE_ARCH'], 'x64'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@0
|
- task: PublishPipelineArtifact@0
|
||||||
@@ -215,20 +180,17 @@ steps:
|
|||||||
yarn gulp "vscode-linux-$(VSCODE_ARCH)-build-deb"
|
yarn gulp "vscode-linux-$(VSCODE_ARCH)-build-deb"
|
||||||
yarn gulp "vscode-linux-$(VSCODE_ARCH)-build-rpm"
|
yarn gulp "vscode-linux-$(VSCODE_ARCH)-build-rpm"
|
||||||
displayName: Build deb, rpm packages
|
displayName: Build deb, rpm packages
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
yarn gulp "vscode-linux-$(VSCODE_ARCH)-prepare-snap"
|
yarn gulp "vscode-linux-$(VSCODE_ARCH)-prepare-snap"
|
||||||
displayName: Prepare snap package
|
displayName: Prepare snap package
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
# needed for code signing
|
# needed for code signing
|
||||||
- task: UseDotNet@2
|
- task: UseDotNet@2
|
||||||
displayName: "Install .NET Core SDK 2.x"
|
displayName: "Install .NET Core SDK 2.x"
|
||||||
inputs:
|
inputs:
|
||||||
version: 2.x
|
version: 2.x
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
||||||
inputs:
|
inputs:
|
||||||
@@ -248,7 +210,6 @@ steps:
|
|||||||
]
|
]
|
||||||
SessionTimeout: 120
|
SessionTimeout: 120
|
||||||
displayName: Codesign rpm
|
displayName: Codesign rpm
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -258,34 +219,12 @@ steps:
|
|||||||
VSCODE_ARCH="$(VSCODE_ARCH)" \
|
VSCODE_ARCH="$(VSCODE_ARCH)" \
|
||||||
./build/azure-pipelines/linux/publish.sh
|
./build/azure-pipelines/linux/publish.sh
|
||||||
displayName: Publish
|
displayName: Publish
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(DEB_PATH)
|
|
||||||
artifact: vscode-linux-deb-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish deb package
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(RPM_PATH)
|
|
||||||
artifact: vscode-linux-rpm-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish rpm package
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/vscode-server-linux-$(VSCODE_ARCH).tar.gz
|
|
||||||
artifact: vscode-server-linux-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish server archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/vscode-server-linux-$(VSCODE_ARCH)-web.tar.gz
|
|
||||||
artifact: vscode-server-linux-$(VSCODE_ARCH)-web
|
|
||||||
displayName: Publish web server archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@0
|
- task: PublishPipelineArtifact@0
|
||||||
displayName: "Publish Pipeline Artifact"
|
displayName: "Publish Pipeline Artifact"
|
||||||
inputs:
|
inputs:
|
||||||
artifactName: "snap-$(VSCODE_ARCH)"
|
artifactName: "snap-$(VSCODE_ARCH)"
|
||||||
targetPath: .build/linux/snap-tarball
|
targetPath: .build/linux/snap-tarball
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
||||||
displayName: "Component Detection"
|
displayName: "Component Detection"
|
||||||
|
|||||||
@@ -26,17 +26,6 @@ rm -rf $ROOT/vscode-server-*.tar.*
|
|||||||
|
|
||||||
node build/azure-pipelines/common/createAsset.js "server-$PLATFORM_LINUX" archive-unsigned "$SERVER_TARBALL_FILENAME" "$SERVER_TARBALL_PATH"
|
node build/azure-pipelines/common/createAsset.js "server-$PLATFORM_LINUX" archive-unsigned "$SERVER_TARBALL_FILENAME" "$SERVER_TARBALL_PATH"
|
||||||
|
|
||||||
# Publish Remote Extension Host (Web)
|
|
||||||
LEGACY_SERVER_BUILD_NAME="vscode-reh-web-$PLATFORM_LINUX"
|
|
||||||
SERVER_BUILD_NAME="vscode-server-$PLATFORM_LINUX-web"
|
|
||||||
SERVER_TARBALL_FILENAME="vscode-server-$PLATFORM_LINUX-web.tar.gz"
|
|
||||||
SERVER_TARBALL_PATH="$ROOT/$SERVER_TARBALL_FILENAME"
|
|
||||||
|
|
||||||
rm -rf $ROOT/vscode-server-*-web.tar.*
|
|
||||||
(cd $ROOT && mv $LEGACY_SERVER_BUILD_NAME $SERVER_BUILD_NAME && tar --owner=0 --group=0 -czf $SERVER_TARBALL_PATH $SERVER_BUILD_NAME)
|
|
||||||
|
|
||||||
node build/azure-pipelines/common/createAsset.js "server-$PLATFORM_LINUX-web" archive-unsigned "$SERVER_TARBALL_FILENAME" "$SERVER_TARBALL_PATH"
|
|
||||||
|
|
||||||
# Publish DEB
|
# Publish DEB
|
||||||
case $VSCODE_ARCH in
|
case $VSCODE_ARCH in
|
||||||
x64) DEB_ARCH="amd64" ;;
|
x64) DEB_ARCH="amd64" ;;
|
||||||
@@ -69,7 +58,3 @@ mkdir -p $REPO/.build/linux/snap-tarball
|
|||||||
SNAP_TARBALL_PATH="$REPO/.build/linux/snap-tarball/snap-$VSCODE_ARCH.tar.gz"
|
SNAP_TARBALL_PATH="$REPO/.build/linux/snap-tarball/snap-$VSCODE_ARCH.tar.gz"
|
||||||
rm -rf $SNAP_TARBALL_PATH
|
rm -rf $SNAP_TARBALL_PATH
|
||||||
(cd .build/linux && tar -czf $SNAP_TARBALL_PATH snap)
|
(cd .build/linux && tar -czf $SNAP_TARBALL_PATH snap)
|
||||||
|
|
||||||
# Export DEB_PATH, RPM_PATH
|
|
||||||
echo "##vso[task.setvariable variable=DEB_PATH]$DEB_PATH"
|
|
||||||
echo "##vso[task.setvariable variable=RPM_PATH]$RPM_PATH"
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
steps:
|
steps:
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
@@ -54,11 +54,3 @@ steps:
|
|||||||
AZURE_DOCUMENTDB_MASTERKEY="$(builds-docdb-key-readwrite)" \
|
AZURE_DOCUMENTDB_MASTERKEY="$(builds-docdb-key-readwrite)" \
|
||||||
AZURE_STORAGE_ACCESS_KEY_2="$(vscode-storage-key)" \
|
AZURE_STORAGE_ACCESS_KEY_2="$(vscode-storage-key)" \
|
||||||
node build/azure-pipelines/common/createAsset.js "linux-snap-$(VSCODE_ARCH)" package "$SNAP_FILENAME" "$SNAP_PATH"
|
node build/azure-pipelines/common/createAsset.js "linux-snap-$(VSCODE_ARCH)" package "$SNAP_FILENAME" "$SNAP_PATH"
|
||||||
|
|
||||||
# Export SNAP_PATH
|
|
||||||
echo "##vso[task.setvariable variable=SNAP_PATH]$SNAP_PATH"
|
|
||||||
|
|
||||||
- publish: $(SNAP_PATH)
|
|
||||||
artifact: vscode-linux-snap-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish snap package
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|||||||
@@ -2,6 +2,27 @@ parameters:
|
|||||||
extensionsToUnitTest: []
|
extensionsToUnitTest: []
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
displayName: Prepare cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
displayName: Restore Cache - Compiled Files
|
||||||
|
inputs:
|
||||||
|
keyfile: 'build/.cachesalt, .build/commit, .build/quality'
|
||||||
|
targetfolder: '.build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min'
|
||||||
|
vstsFeed: 'BuildCache'
|
||||||
|
platformIndependent: true
|
||||||
|
alias: 'Compilation'
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.13.0"
|
versionSpec: "12.13.0"
|
||||||
@@ -17,16 +38,6 @@ steps:
|
|||||||
KeyVaultName: ado-secrets
|
KeyVaultName: ado-secrets
|
||||||
SecretsFilter: 'github-distro-mixin-password'
|
SecretsFilter: 'github-distro-mixin-password'
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
displayName: Download compilation output
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf $(Pipeline.Workspace)/compilation.tar.gz
|
|
||||||
displayName: Extract compilation output
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
cat << EOF > ~/.netrc
|
cat << EOF > ~/.netrc
|
||||||
@@ -46,23 +57,12 @@ steps:
|
|||||||
git merge $(node -p "require('./package.json').distro")
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- script: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
mkdir -p .build
|
|
||||||
node build/azure-pipelines/common/sql-computeNodeModulesCacheKey.js > .build/yarnlockhash
|
|
||||||
displayName: Prepare yarn cache key
|
|
||||||
|
|
||||||
- task: Cache@2
|
|
||||||
displayName: Restore Cache - Node Modules
|
displayName: Restore Cache - Node Modules
|
||||||
inputs:
|
inputs:
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
path: .build/node_modules_cache
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
vstsFeed: 'BuildCache'
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf .build/node_modules_cache/cache.tgz
|
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules archive
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -70,21 +70,21 @@ steps:
|
|||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: $(github-distro-mixin-password)
|
GITHUB_TOKEN: $(github-distro-mixin-password)
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
set -e
|
displayName: Save Cache - Node Modules
|
||||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
inputs:
|
||||||
mkdir -p .build/node_modules_cache
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
tar -czf .build/node_modules_cache/cache.tgz --files-from .build/node_modules_list.txt
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
vstsFeed: 'BuildCache'
|
||||||
displayName: Create node_modules archive
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
yarn postinstall
|
yarn postinstall
|
||||||
displayName: Run postinstall scripts
|
displayName: Run postinstall scripts
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -95,7 +95,6 @@ steps:
|
|||||||
set -e
|
set -e
|
||||||
yarn gulp vscode-linux-x64-min-ci
|
yarn gulp vscode-linux-x64-min-ci
|
||||||
yarn gulp vscode-web-min-ci
|
yarn gulp vscode-web-min-ci
|
||||||
yarn gulp vscode-reh-web-linux-x64-min
|
|
||||||
displayName: Build
|
displayName: Build
|
||||||
env:
|
env:
|
||||||
VSCODE_MIXIN_PASSWORD: $(github-distro-mixin-password)
|
VSCODE_MIXIN_PASSWORD: $(github-distro-mixin-password)
|
||||||
@@ -107,11 +106,6 @@ steps:
|
|||||||
yarn gulp package-external-extensions
|
yarn gulp package-external-extensions
|
||||||
displayName: Package External extensions
|
displayName: Package External extensions
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
yarn gulp package-langpacks
|
|
||||||
displayName: Package Langpacks
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
service xvfb start
|
service xvfb start
|
||||||
@@ -137,19 +131,16 @@ steps:
|
|||||||
displayName: Run integration tests (Electron)
|
displayName: Run integration tests (Electron)
|
||||||
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- ${{each extension in parameters.extensionsToUnitTest}}:
|
||||||
# Figure out the full absolute path of the product we just built
|
- script: |
|
||||||
# including the remote server and configure the unit tests
|
set -e
|
||||||
# to run with these builds instead of running out of sources.
|
APP_ROOT=$(agent.builddirectory)/azuredatastudio-linux-x64
|
||||||
set -e
|
APP_NAME=$(node -p "require(\"$APP_ROOT/resources/app/product.json\").applicationName")
|
||||||
APP_ROOT=$(agent.builddirectory)/azuredatastudio-linux-x64
|
export INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
||||||
APP_NAME=$(node -p "require(\"$APP_ROOT/resources/app/product.json\").applicationName")
|
export NO_CLEANUP=1
|
||||||
INTEGRATION_TEST_ELECTRON_PATH="$APP_ROOT/$APP_NAME" \
|
DISPLAY=:10 node ./scripts/test-extensions-unit.js ${{ extension }}
|
||||||
NO_CLEANUP=1 \
|
displayName: 'Run ${{ extension }} Stable Extension Unit Tests'
|
||||||
VSCODE_REMOTE_SERVER_PATH="$(agent.builddirectory)/azuredatastudio-reh-linux-x64" \
|
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
||||||
DISPLAY=:10 ./scripts/test-extensions-unit.sh --build --tfs "Extension Unit Tests"
|
|
||||||
displayName: 'Run Stable Extension Unit Tests'
|
|
||||||
condition: and(succeeded(), eq(variables['RUN_TESTS'], 'true'))
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -171,6 +162,7 @@ steps:
|
|||||||
# Only archive directories we want for debugging purposes
|
# Only archive directories we want for debugging purposes
|
||||||
tar -czvf $(Build.ArtifactStagingDirectory)/logs/linux-x64/$folder.tar.gz $folder/User $folder/logs
|
tar -czvf $(Build.ArtifactStagingDirectory)/logs/linux-x64/$folder.tar.gz $folder/User $folder/logs
|
||||||
done
|
done
|
||||||
|
|
||||||
displayName: Archive Logs
|
displayName: Archive Logs
|
||||||
continueOnError: true
|
continueOnError: true
|
||||||
condition: succeededOrFailed()
|
condition: succeededOrFailed()
|
||||||
@@ -196,7 +188,7 @@ steps:
|
|||||||
inputs:
|
inputs:
|
||||||
ConnectedServiceName: 'Code Signing'
|
ConnectedServiceName: 'Code Signing'
|
||||||
FolderPath: '$(Build.SourcesDirectory)/.build'
|
FolderPath: '$(Build.SourcesDirectory)/.build'
|
||||||
Pattern: 'extensions/*.vsix,langpacks/*.vsix'
|
Pattern: 'extensions/*.vsix'
|
||||||
signConfigType: inlineSignParams
|
signConfigType: inlineSignParams
|
||||||
inlineOperation: |
|
inlineOperation: |
|
||||||
[
|
[
|
||||||
@@ -221,22 +213,9 @@ steps:
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
SessionTimeout: 120
|
SessionTimeout: 120
|
||||||
displayName: 'Signing Extensions and Langpacks'
|
displayName: 'Signing Extensions'
|
||||||
condition: and(succeeded(), eq(variables['signed'], true))
|
condition: and(succeeded(), eq(variables['signed'], true))
|
||||||
|
|
||||||
# - script: |
|
|
||||||
# set -e
|
|
||||||
# cd ./extensions/mssql/node_modules/@microsoft/ads-kerberos
|
|
||||||
# # npx node-gyp rebuild
|
|
||||||
# yarn install
|
|
||||||
# displayName: Recompile native node modules
|
|
||||||
|
|
||||||
# - script: |
|
|
||||||
# set -e
|
|
||||||
# VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
|
||||||
# yarn gulp vscode-reh-web-linux-x64-min
|
|
||||||
# displayName: Build web server
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
./build/azure-pipelines/linux/createDrop.sh
|
./build/azure-pipelines/linux/createDrop.sh
|
||||||
@@ -258,13 +237,6 @@ steps:
|
|||||||
continueOnError: true
|
continueOnError: true
|
||||||
condition: and(succeededOrFailed(), eq(variables['RUN_TESTS'], 'true'))
|
condition: and(succeededOrFailed(), eq(variables['RUN_TESTS'], 'true'))
|
||||||
|
|
||||||
- task: PublishBuildArtifacts@1
|
|
||||||
displayName: 'Publish Artifact: crash reports'
|
|
||||||
inputs:
|
|
||||||
PathtoPublish: '$(Build.SourcesDirectory)/.build/crashes'
|
|
||||||
ArtifactName: crashes
|
|
||||||
condition: and(succeededOrFailed(), eq(variables['RUN_TESTS'], 'true'))
|
|
||||||
|
|
||||||
- task: PublishBuildArtifacts@1
|
- task: PublishBuildArtifacts@1
|
||||||
displayName: 'Publish Artifact: drop'
|
displayName: 'Publish Artifact: drop'
|
||||||
condition: succeededOrFailed()
|
condition: succeededOrFailed()
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
trigger: none
|
||||||
pr: none
|
pr: none
|
||||||
|
|
||||||
schedules:
|
schedules:
|
||||||
@@ -7,108 +8,11 @@ schedules:
|
|||||||
include:
|
include:
|
||||||
- master
|
- master
|
||||||
|
|
||||||
parameters:
|
|
||||||
- name: VSCODE_QUALITY
|
|
||||||
displayName: Quality
|
|
||||||
type: string
|
|
||||||
default: insider
|
|
||||||
values:
|
|
||||||
- exploration
|
|
||||||
- insider
|
|
||||||
- stable
|
|
||||||
- name: ENABLE_TERRAPIN
|
|
||||||
displayName: "Enable Terrapin"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_WIN32
|
|
||||||
displayName: "🎯 Windows x64"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_WIN32_32BIT
|
|
||||||
displayName: "🎯 Windows ia32"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_WIN32_ARM64
|
|
||||||
displayName: "🎯 Windows arm64"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_LINUX
|
|
||||||
displayName: "🎯 Linux x64"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_LINUX_ARM64
|
|
||||||
displayName: "🎯 Linux arm64"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_LINUX_ARMHF
|
|
||||||
displayName: "🎯 Linux armhf"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_LINUX_ALPINE
|
|
||||||
displayName: "🎯 Alpine Linux"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_MACOS
|
|
||||||
displayName: "🎯 macOS x64"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_MACOS_ARM64
|
|
||||||
displayName: "🎯 macOS arm64"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_MACOS_UNIVERSAL
|
|
||||||
displayName: "🎯 macOS universal"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_BUILD_WEB
|
|
||||||
displayName: "🎯 Web"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_PUBLISH
|
|
||||||
displayName: "Publish to builds.code.visualstudio.com"
|
|
||||||
type: boolean
|
|
||||||
default: true
|
|
||||||
- name: VSCODE_RELEASE
|
|
||||||
displayName: "Release build if successful"
|
|
||||||
type: boolean
|
|
||||||
default: false
|
|
||||||
- name: VSCODE_COMPILE_ONLY
|
|
||||||
displayName: "Run Compile stage exclusively"
|
|
||||||
type: boolean
|
|
||||||
default: false
|
|
||||||
- name: VSCODE_STEP_ON_IT
|
|
||||||
displayName: "Skip tests"
|
|
||||||
type: boolean
|
|
||||||
default: false
|
|
||||||
|
|
||||||
variables:
|
|
||||||
- name: ENABLE_TERRAPIN
|
|
||||||
value: ${{ eq(parameters.ENABLE_TERRAPIN, true) }}
|
|
||||||
- name: VSCODE_QUALITY
|
|
||||||
value: ${{ parameters.VSCODE_QUALITY }}
|
|
||||||
- name: VSCODE_BUILD_STAGE_WINDOWS
|
|
||||||
value: ${{ or(eq(parameters.VSCODE_BUILD_WIN32, true), eq(parameters.VSCODE_BUILD_WIN32_32BIT, true), eq(parameters.VSCODE_BUILD_WIN32_ARM64, true)) }}
|
|
||||||
- name: VSCODE_BUILD_STAGE_LINUX
|
|
||||||
value: ${{ or(eq(parameters.VSCODE_BUILD_LINUX, true), eq(parameters.VSCODE_BUILD_LINUX_ARMHF, true), eq(parameters.VSCODE_BUILD_LINUX_ARM64, true), eq(parameters.VSCODE_BUILD_LINUX_ALPINE, true), eq(parameters.VSCODE_BUILD_WEB, true)) }}
|
|
||||||
- name: VSCODE_BUILD_STAGE_MACOS
|
|
||||||
value: ${{ or(eq(parameters.VSCODE_BUILD_MACOS, true), eq(parameters.VSCODE_BUILD_MACOS_ARM64, true)) }}
|
|
||||||
- name: VSCODE_CIBUILD
|
|
||||||
value: ${{ in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI') }}
|
|
||||||
- name: VSCODE_PUBLISH
|
|
||||||
value: ${{ and(eq(parameters.VSCODE_PUBLISH, true), eq(variables.VSCODE_CIBUILD, false)) }}
|
|
||||||
- name: VSCODE_SCHEDULEDBUILD
|
|
||||||
value: ${{ eq(variables['Build.Reason'], 'Schedule') }}
|
|
||||||
- name: VSCODE_STEP_ON_IT
|
|
||||||
value: ${{ eq(parameters.VSCODE_STEP_ON_IT, true) }}
|
|
||||||
- name: VSCODE_BUILD_MACOS_UNIVERSAL
|
|
||||||
value: ${{ and(eq(variables['VSCODE_PUBLISH'], true), eq(parameters.VSCODE_BUILD_MACOS, true), eq(parameters.VSCODE_BUILD_MACOS_ARM64, true), eq(parameters.VSCODE_BUILD_MACOS_UNIVERSAL, true)) }}
|
|
||||||
|
|
||||||
resources:
|
resources:
|
||||||
containers:
|
containers:
|
||||||
- container: vscode-x64
|
- container: vscode-x64
|
||||||
image: vscodehub.azurecr.io/vscode-linux-build-agent:bionic-x64
|
image: vscodehub.azurecr.io/vscode-linux-build-agent:x64
|
||||||
endpoint: VSCodeHub
|
endpoint: VSCodeHub
|
||||||
options: --user 0:0
|
|
||||||
- container: vscode-arm64
|
- container: vscode-arm64
|
||||||
image: vscodehub.azurecr.io/vscode-linux-build-agent:stretch-arm64
|
image: vscodehub.azurecr.io/vscode-linux-build-agent:stretch-arm64
|
||||||
endpoint: VSCodeHub
|
endpoint: VSCodeHub
|
||||||
@@ -122,189 +26,177 @@ stages:
|
|||||||
- stage: Compile
|
- stage: Compile
|
||||||
jobs:
|
jobs:
|
||||||
- job: Compile
|
- job: Compile
|
||||||
pool: compile
|
pool:
|
||||||
|
vmImage: "Ubuntu-16.04"
|
||||||
|
container: vscode-x64
|
||||||
variables:
|
variables:
|
||||||
VSCODE_ARCH: x64
|
VSCODE_ARCH: x64
|
||||||
steps:
|
steps:
|
||||||
- template: product-compile.yml
|
- template: product-compile.yml
|
||||||
|
|
||||||
- ${{ if and(eq(parameters.VSCODE_COMPILE_ONLY, false), eq(variables['VSCODE_BUILD_STAGE_WINDOWS'], true)) }}:
|
- stage: Windows
|
||||||
- stage: Windows
|
dependsOn:
|
||||||
dependsOn:
|
- Compile
|
||||||
- Compile
|
condition: and(succeeded(), eq(variables['VSCODE_COMPILE_ONLY'], 'false'))
|
||||||
pool:
|
pool:
|
||||||
vmImage: VS2017-Win2016
|
vmImage: VS2017-Win2016
|
||||||
jobs:
|
jobs:
|
||||||
|
- job: Windows
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WIN32'], 'true'))
|
||||||
|
timeoutInMinutes: 90
|
||||||
|
variables:
|
||||||
|
VSCODE_ARCH: x64
|
||||||
|
steps:
|
||||||
|
- template: win32/product-build-win32.yml
|
||||||
|
|
||||||
- ${{ if eq(parameters.VSCODE_BUILD_WIN32, true) }}:
|
- job: Windows32
|
||||||
- job: Windows
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WIN32_32BIT'], 'true'))
|
||||||
timeoutInMinutes: 90
|
timeoutInMinutes: 90
|
||||||
variables:
|
variables:
|
||||||
VSCODE_ARCH: x64
|
VSCODE_ARCH: ia32
|
||||||
steps:
|
steps:
|
||||||
- template: win32/product-build-win32.yml
|
- template: win32/product-build-win32.yml
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_WIN32_32BIT, true)) }}:
|
- job: WindowsARM64
|
||||||
- job: Windows32
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WIN32_ARM64'], 'true'))
|
||||||
timeoutInMinutes: 90
|
timeoutInMinutes: 90
|
||||||
variables:
|
variables:
|
||||||
VSCODE_ARCH: ia32
|
VSCODE_ARCH: arm64
|
||||||
steps:
|
steps:
|
||||||
- template: win32/product-build-win32.yml
|
- template: win32/product-build-win32.yml
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_WIN32_ARM64, true)) }}:
|
- stage: Linux
|
||||||
- job: WindowsARM64
|
dependsOn:
|
||||||
timeoutInMinutes: 90
|
- Compile
|
||||||
variables:
|
condition: and(succeeded(), eq(variables['VSCODE_COMPILE_ONLY'], 'false'))
|
||||||
VSCODE_ARCH: arm64
|
pool:
|
||||||
steps:
|
vmImage: "Ubuntu-16.04"
|
||||||
- template: win32/product-build-win32.yml
|
jobs:
|
||||||
|
- job: Linux
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX'], 'true'))
|
||||||
|
container: vscode-x64
|
||||||
|
variables:
|
||||||
|
VSCODE_ARCH: x64
|
||||||
|
NPM_ARCH: x64
|
||||||
|
steps:
|
||||||
|
- template: linux/product-build-linux.yml
|
||||||
|
|
||||||
- ${{ if and(eq(parameters.VSCODE_COMPILE_ONLY, false), eq(variables['VSCODE_BUILD_STAGE_LINUX'], true)) }}:
|
- job: LinuxSnap
|
||||||
- stage: Linux
|
dependsOn:
|
||||||
dependsOn:
|
|
||||||
- Compile
|
|
||||||
pool:
|
|
||||||
vmImage: "Ubuntu-18.04"
|
|
||||||
jobs:
|
|
||||||
|
|
||||||
- ${{ if eq(parameters.VSCODE_BUILD_LINUX, true) }}:
|
|
||||||
- job: Linux
|
|
||||||
container: vscode-x64
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: x64
|
|
||||||
NPM_ARCH: x64
|
|
||||||
steps:
|
|
||||||
- template: linux/product-build-linux.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_LINUX, true)) }}:
|
|
||||||
- job: LinuxSnap
|
|
||||||
dependsOn:
|
|
||||||
- Linux
|
|
||||||
container: snapcraft
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: x64
|
|
||||||
steps:
|
|
||||||
- template: linux/snap-build-linux.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_LINUX_ARMHF, true)) }}:
|
|
||||||
- job: LinuxArmhf
|
|
||||||
container: vscode-armhf
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: armhf
|
|
||||||
NPM_ARCH: armv7l
|
|
||||||
steps:
|
|
||||||
- template: linux/product-build-linux.yml
|
|
||||||
|
|
||||||
# TODO@joaomoreno: We don't ship ARM snaps for now
|
|
||||||
- ${{ if and(false, eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_LINUX_ARMHF, true)) }}:
|
|
||||||
- job: LinuxSnapArmhf
|
|
||||||
dependsOn:
|
|
||||||
- LinuxArmhf
|
|
||||||
container: snapcraft
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: armhf
|
|
||||||
steps:
|
|
||||||
- template: linux/snap-build-linux.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_LINUX_ARM64, true)) }}:
|
|
||||||
- job: LinuxArm64
|
|
||||||
container: vscode-arm64
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: arm64
|
|
||||||
NPM_ARCH: arm64
|
|
||||||
steps:
|
|
||||||
- template: linux/product-build-linux.yml
|
|
||||||
|
|
||||||
# TODO@joaomoreno: We don't ship ARM snaps for now
|
|
||||||
- ${{ if and(false, eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_LINUX_ARM64, true)) }}:
|
|
||||||
- job: LinuxSnapArm64
|
|
||||||
dependsOn:
|
|
||||||
- LinuxArm64
|
|
||||||
container: snapcraft
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: arm64
|
|
||||||
steps:
|
|
||||||
- template: linux/snap-build-linux.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_LINUX_ALPINE, true)) }}:
|
|
||||||
- job: LinuxAlpine
|
|
||||||
steps:
|
|
||||||
- template: linux/product-build-alpine.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_WEB, true)) }}:
|
|
||||||
- job: LinuxWeb
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: x64
|
|
||||||
steps:
|
|
||||||
- template: web/product-build-web.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(parameters.VSCODE_COMPILE_ONLY, false), eq(variables['VSCODE_BUILD_STAGE_MACOS'], true)) }}:
|
|
||||||
- stage: macOS
|
|
||||||
dependsOn:
|
|
||||||
- Compile
|
|
||||||
pool:
|
|
||||||
vmImage: macOS-latest
|
|
||||||
jobs:
|
|
||||||
|
|
||||||
- ${{ if eq(parameters.VSCODE_BUILD_MACOS, true) }}:
|
|
||||||
- job: macOS
|
|
||||||
timeoutInMinutes: 90
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: x64
|
|
||||||
steps:
|
|
||||||
- template: darwin/product-build-darwin.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_CIBUILD'], false), eq(parameters.VSCODE_BUILD_MACOS_ARM64, true)) }}:
|
|
||||||
- job: macOSARM64
|
|
||||||
timeoutInMinutes: 90
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: arm64
|
|
||||||
steps:
|
|
||||||
- template: darwin/product-build-darwin.yml
|
|
||||||
|
|
||||||
- ${{ if eq(variables['VSCODE_BUILD_MACOS_UNIVERSAL'], true) }}:
|
|
||||||
- job: macOSUniversal
|
|
||||||
dependsOn:
|
|
||||||
- macOS
|
|
||||||
- macOSARM64
|
|
||||||
timeoutInMinutes: 90
|
|
||||||
variables:
|
|
||||||
VSCODE_ARCH: universal
|
|
||||||
steps:
|
|
||||||
- template: darwin/product-build-darwin.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(variables['VSCODE_PUBLISH'], true), eq(parameters.VSCODE_COMPILE_ONLY, false)) }}:
|
|
||||||
- stage: Mooncake
|
|
||||||
dependsOn:
|
|
||||||
- ${{ if eq(variables['VSCODE_BUILD_STAGE_WINDOWS'], true) }}:
|
|
||||||
- Windows
|
|
||||||
- ${{ if eq(variables['VSCODE_BUILD_STAGE_LINUX'], true) }}:
|
|
||||||
- Linux
|
- Linux
|
||||||
- ${{ if eq(variables['VSCODE_BUILD_STAGE_MACOS'], true) }}:
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX'], 'true'))
|
||||||
- macOS
|
container: snapcraft
|
||||||
condition: succeededOrFailed()
|
variables:
|
||||||
pool:
|
VSCODE_ARCH: x64
|
||||||
vmImage: "Ubuntu-18.04"
|
steps:
|
||||||
jobs:
|
- template: linux/snap-build-linux.yml
|
||||||
- job: SyncMooncake
|
|
||||||
displayName: Sync Mooncake
|
|
||||||
steps:
|
|
||||||
- template: sync-mooncake.yml
|
|
||||||
|
|
||||||
- ${{ if and(eq(parameters.VSCODE_COMPILE_ONLY, false), or(eq(parameters.VSCODE_RELEASE, true), and(in(parameters.VSCODE_QUALITY, 'insider', 'exploration'), eq(variables['VSCODE_SCHEDULEDBUILD'], true)))) }}:
|
- job: LinuxArmhf
|
||||||
- stage: Release
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX_ARMHF'], 'true'))
|
||||||
dependsOn:
|
container: vscode-armhf
|
||||||
- ${{ if eq(variables['VSCODE_BUILD_STAGE_WINDOWS'], true) }}:
|
variables:
|
||||||
- Windows
|
VSCODE_ARCH: armhf
|
||||||
- ${{ if eq(variables['VSCODE_BUILD_STAGE_LINUX'], true) }}:
|
NPM_ARCH: armv7l
|
||||||
- Linux
|
steps:
|
||||||
- ${{ if eq(variables['VSCODE_BUILD_STAGE_MACOS'], true) }}:
|
- template: linux/product-build-linux.yml
|
||||||
- macOS
|
|
||||||
pool:
|
- job: LinuxSnapArmhf
|
||||||
vmImage: "Ubuntu-18.04"
|
dependsOn:
|
||||||
jobs:
|
- LinuxArmhf
|
||||||
- job: ReleaseBuild
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX_ARMHF'], 'true'))
|
||||||
displayName: Release Build
|
container: snapcraft
|
||||||
steps:
|
variables:
|
||||||
- template: release.yml
|
VSCODE_ARCH: armhf
|
||||||
|
steps:
|
||||||
|
- template: linux/snap-build-linux.yml
|
||||||
|
|
||||||
|
- job: LinuxArm64
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX_ARM64'], 'true'))
|
||||||
|
container: vscode-arm64
|
||||||
|
variables:
|
||||||
|
VSCODE_ARCH: arm64
|
||||||
|
NPM_ARCH: arm64
|
||||||
|
steps:
|
||||||
|
- template: linux/product-build-linux.yml
|
||||||
|
|
||||||
|
- job: LinuxSnapArm64
|
||||||
|
dependsOn:
|
||||||
|
- LinuxArm64
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX_ARM64'], 'true'))
|
||||||
|
container: snapcraft
|
||||||
|
variables:
|
||||||
|
VSCODE_ARCH: arm64
|
||||||
|
steps:
|
||||||
|
- template: linux/snap-build-linux.yml
|
||||||
|
|
||||||
|
- job: LinuxAlpine
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX_ALPINE'], 'true'))
|
||||||
|
steps:
|
||||||
|
- template: linux/product-build-alpine.yml
|
||||||
|
|
||||||
|
- job: LinuxWeb
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WEB'], 'true'))
|
||||||
|
variables:
|
||||||
|
VSCODE_ARCH: x64
|
||||||
|
steps:
|
||||||
|
- template: web/product-build-web.yml
|
||||||
|
|
||||||
|
- stage: macOS
|
||||||
|
dependsOn:
|
||||||
|
- Compile
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_COMPILE_ONLY'], 'false'))
|
||||||
|
pool:
|
||||||
|
vmImage: macOS-latest
|
||||||
|
jobs:
|
||||||
|
- job: macOS
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_MACOS'], 'true'))
|
||||||
|
timeoutInMinutes: 90
|
||||||
|
variables:
|
||||||
|
VSCODE_ARCH: x64
|
||||||
|
steps:
|
||||||
|
- template: darwin/product-build-darwin.yml
|
||||||
|
|
||||||
|
- stage: macOSARM64
|
||||||
|
dependsOn:
|
||||||
|
- Compile
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_COMPILE_ONLY'], 'false'))
|
||||||
|
pool:
|
||||||
|
vmImage: macOS-latest
|
||||||
|
jobs:
|
||||||
|
- job: macOSARM64
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_MACOS_ARM64'], 'true'))
|
||||||
|
timeoutInMinutes: 90
|
||||||
|
variables:
|
||||||
|
VSCODE_ARCH: arm64
|
||||||
|
steps:
|
||||||
|
- template: darwin/product-build-darwin.yml
|
||||||
|
|
||||||
|
- stage: Mooncake
|
||||||
|
dependsOn:
|
||||||
|
- Windows
|
||||||
|
- Linux
|
||||||
|
- macOS
|
||||||
|
- macOSARM64
|
||||||
|
condition: and(succeededOrFailed(), eq(variables['VSCODE_COMPILE_ONLY'], 'false'))
|
||||||
|
pool:
|
||||||
|
vmImage: "Ubuntu-16.04"
|
||||||
|
jobs:
|
||||||
|
- job: SyncMooncake
|
||||||
|
displayName: Sync Mooncake
|
||||||
|
steps:
|
||||||
|
- template: sync-mooncake.yml
|
||||||
|
|
||||||
|
- stage: Publish
|
||||||
|
dependsOn:
|
||||||
|
- Windows
|
||||||
|
- Linux
|
||||||
|
- macOS
|
||||||
|
- macOSARM64
|
||||||
|
condition: and(succeeded(), eq(variables['VSCODE_COMPILE_ONLY'], 'false'), or(eq(variables['VSCODE_RELEASE'], 'true'), and(or(eq(variables['VSCODE_QUALITY'], 'insider'), eq(variables['VSCODE_QUALITY'], 'exploration')), eq(variables['Build.Reason'], 'Schedule'))))
|
||||||
|
pool:
|
||||||
|
vmImage: "Ubuntu-16.04"
|
||||||
|
jobs:
|
||||||
|
- job: BuildService
|
||||||
|
displayName: Build Service
|
||||||
|
steps:
|
||||||
|
- template: release.yml
|
||||||
|
|||||||
@@ -1,17 +1,36 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
echo -n $ENABLE_TERRAPIN > .build/terrapin
|
||||||
|
displayName: Prepare compilation cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: "build/.cachesalt, .build/commit, .build/quality, .build/terrapin"
|
||||||
|
targetfolder: ".build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
platformIndependent: true
|
||||||
|
alias: "Compilation"
|
||||||
|
dryRun: true
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "1.x"
|
versionSpec: "1.x"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: AzureKeyVault@1
|
- task: AzureKeyVault@1
|
||||||
displayName: "Azure Key Vault: Get Secrets"
|
displayName: "Azure Key Vault: Get Secrets"
|
||||||
inputs:
|
inputs:
|
||||||
azureSubscription: "vscode-builds-subscription"
|
azureSubscription: "vscode-builds-subscription"
|
||||||
KeyVaultName: vscode
|
KeyVaultName: vscode
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -24,22 +43,24 @@ steps:
|
|||||||
git config user.email "vscode@microsoft.com"
|
git config user.email "vscode@microsoft.com"
|
||||||
git config user.name "VSCode"
|
git config user.name "VSCode"
|
||||||
displayName: Prepare tooling
|
displayName: Prepare tooling
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
git pull --no-rebase https://github.com/$(VSCODE_MIXIN_REPO).git $(node -p "require('./package.json').distro")
|
git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git"
|
||||||
|
git fetch distro
|
||||||
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
npx https://aka.ms/enablesecurefeed standAlone
|
npx https://aka.ms/enablesecurefeed standAlone
|
||||||
displayName: Switch to Terrapin packages
|
displayName: Switch to Terrapin packages
|
||||||
timeoutInMinutes: 5
|
timeoutInMinutes: 5
|
||||||
condition: and(succeeded(), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
mkdir -p .build
|
|
||||||
echo -n $(VSCODE_ARCH) > .build/arch
|
echo -n $(VSCODE_ARCH) > .build/arch
|
||||||
echo -n $ENABLE_TERRAPIN > .build/terrapin
|
|
||||||
displayName: Prepare yarn cache flags
|
displayName: Prepare yarn cache flags
|
||||||
|
|
||||||
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
@@ -47,22 +68,11 @@ steps:
|
|||||||
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
vstsFeed: "npm-vscode"
|
vstsFeed: "npm-vscode"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
export npm_config_arch=$(NPM_ARCH)
|
export CHILD_CONCURRENCY="1"
|
||||||
|
|
||||||
if [ -z "$CC" ] || [ -z "$CXX" ]; then
|
|
||||||
export CC=$(which gcc-5)
|
|
||||||
export CXX=$(which g++-5)
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$VSCODE_ARCH" == "x64" ]; then
|
|
||||||
export VSCODE_REMOTE_CC=$(which gcc-4.8)
|
|
||||||
export VSCODE_REMOTE_CXX=$(which g++-4.8)
|
|
||||||
export VSCODE_REMOTE_NODE_GYP=$(which node-gyp)
|
|
||||||
fi
|
|
||||||
|
|
||||||
for i in {1..3}; do # try 3 times, for Terrapin
|
for i in {1..3}; do # try 3 times, for Terrapin
|
||||||
yarn --frozen-lockfile && break
|
yarn --frozen-lockfile && break
|
||||||
if [ $i -eq 3 ]; then
|
if [ $i -eq 3 ]; then
|
||||||
@@ -71,24 +81,50 @@ steps:
|
|||||||
fi
|
fi
|
||||||
echo "Yarn failed $i, trying again..."
|
echo "Yarn failed $i, trying again..."
|
||||||
done
|
done
|
||||||
env:
|
|
||||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
|
||||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
|
||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
inputs:
|
inputs:
|
||||||
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
vstsFeed: "npm-vscode"
|
vstsFeed: "npm-vscode"
|
||||||
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
# Mixin must run before optimize, because the CSS loader will inline small SVGs
|
- script: |
|
||||||
|
set -e
|
||||||
|
yarn postinstall
|
||||||
|
displayName: Run postinstall scripts
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'), eq(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
|
# Mixin must run before optimize, because the CSS loader will
|
||||||
|
# inline small SVGs
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
node build/azure-pipelines/mixin
|
node build/azure-pipelines/mixin
|
||||||
displayName: Mix in quality
|
displayName: Mix in quality
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
yarn gulp hygiene
|
||||||
|
yarn monaco-compile-check
|
||||||
|
yarn valid-layers-check
|
||||||
|
displayName: Run hygiene, monaco compile & valid layers checks
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -
|
||||||
|
./build/azure-pipelines/common/extract-telemetry.sh
|
||||||
|
displayName: Extract Telemetry
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
AZURE_WEBVIEW_STORAGE_ACCESS_KEY="$(vscode-webview-storage-key)" \
|
||||||
|
./build/azure-pipelines/common/publish-webview.sh
|
||||||
|
displayName: Publish Webview
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -98,13 +134,14 @@ steps:
|
|||||||
yarn gulp vscode-reh-linux-x64-min
|
yarn gulp vscode-reh-linux-x64-min
|
||||||
yarn gulp vscode-reh-web-linux-x64-min
|
yarn gulp vscode-reh-web-linux-x64-min
|
||||||
displayName: Compile
|
displayName: Compile
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
AZURE_STORAGE_ACCESS_KEY="$(ticino-storage-key)" \
|
AZURE_STORAGE_ACCESS_KEY="$(ticino-storage-key)" \
|
||||||
node build/azure-pipelines/upload-sourcemaps
|
node build/azure-pipelines/upload-sourcemaps
|
||||||
displayName: Upload sourcemaps
|
displayName: Upload sourcemaps
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -112,16 +149,13 @@ steps:
|
|||||||
AZURE_DOCUMENTDB_MASTERKEY="$(builds-docdb-key-readwrite)" \
|
AZURE_DOCUMENTDB_MASTERKEY="$(builds-docdb-key-readwrite)" \
|
||||||
node build/azure-pipelines/common/createBuild.js $VERSION
|
node build/azure-pipelines/common/createBuild.js $VERSION
|
||||||
displayName: Create build
|
displayName: Create build
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
# we gotta tarball everything in order to preserve file permissions
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -czf $(Build.ArtifactStagingDirectory)/compilation.tar.gz .build out-*
|
|
||||||
displayName: Compress compilation artifact
|
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@1
|
|
||||||
inputs:
|
inputs:
|
||||||
targetPath: $(Build.ArtifactStagingDirectory)/compilation.tar.gz
|
keyfile: "build/.cachesalt, .build/commit, .build/quality, .build/terrapin"
|
||||||
artifactName: Compilation
|
targetfolder: ".build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min"
|
||||||
displayName: Publish compilation artifact
|
vstsFeed: "npm-vscode"
|
||||||
|
platformIndependent: true
|
||||||
|
alias: "Compilation"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|||||||
2
build/azure-pipelines/publish-types/.gitignore
vendored
Normal file
2
build/azure-pipelines/publish-types/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
node_modules/
|
||||||
|
*.js
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const cp = require("child_process");
|
|
||||||
let tag = '';
|
|
||||||
try {
|
|
||||||
tag = cp
|
|
||||||
.execSync('git describe --tags `git rev-list --tags --max-count=1`')
|
|
||||||
.toString()
|
|
||||||
.trim();
|
|
||||||
if (!isValidTag(tag)) {
|
|
||||||
throw Error(`Invalid tag ${tag}`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
catch (err) {
|
|
||||||
console.error(err);
|
|
||||||
console.error('Failed to update types');
|
|
||||||
process.exit(1);
|
|
||||||
}
|
|
||||||
function isValidTag(t) {
|
|
||||||
if (t.split('.').length !== 3) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
const [major, minor, bug] = t.split('.');
|
|
||||||
// Only release for tags like 1.34.0
|
|
||||||
if (bug !== '0') {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (isNaN(parseInt(major, 10)) || isNaN(parseInt(minor, 10))) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
@@ -9,7 +9,7 @@ pr: none
|
|||||||
steps:
|
steps:
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
|
|||||||
@@ -1,72 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const fs = require("fs");
|
|
||||||
const cp = require("child_process");
|
|
||||||
const path = require("path");
|
|
||||||
let tag = '';
|
|
||||||
try {
|
|
||||||
tag = cp
|
|
||||||
.execSync('git describe --tags `git rev-list --tags --max-count=1`')
|
|
||||||
.toString()
|
|
||||||
.trim();
|
|
||||||
const dtsUri = `https://raw.githubusercontent.com/microsoft/vscode/${tag}/src/vs/vscode.d.ts`;
|
|
||||||
const outPath = path.resolve(process.cwd(), 'DefinitelyTyped/types/vscode/index.d.ts');
|
|
||||||
cp.execSync(`curl ${dtsUri} --output ${outPath}`);
|
|
||||||
updateDTSFile(outPath, tag);
|
|
||||||
console.log(`Done updating vscode.d.ts at ${outPath}`);
|
|
||||||
}
|
|
||||||
catch (err) {
|
|
||||||
console.error(err);
|
|
||||||
console.error('Failed to update types');
|
|
||||||
process.exit(1);
|
|
||||||
}
|
|
||||||
function updateDTSFile(outPath, tag) {
|
|
||||||
const oldContent = fs.readFileSync(outPath, 'utf-8');
|
|
||||||
const newContent = getNewFileContent(oldContent, tag);
|
|
||||||
fs.writeFileSync(outPath, newContent);
|
|
||||||
}
|
|
||||||
function repeat(str, times) {
|
|
||||||
const result = new Array(times);
|
|
||||||
for (let i = 0; i < times; i++) {
|
|
||||||
result[i] = str;
|
|
||||||
}
|
|
||||||
return result.join('');
|
|
||||||
}
|
|
||||||
function convertTabsToSpaces(str) {
|
|
||||||
return str.replace(/\t/gm, value => repeat(' ', value.length));
|
|
||||||
}
|
|
||||||
function getNewFileContent(content, tag) {
|
|
||||||
const oldheader = [
|
|
||||||
`/*---------------------------------------------------------------------------------------------`,
|
|
||||||
` * Copyright (c) Microsoft Corporation. All rights reserved.`,
|
|
||||||
` * Licensed under the Source EULA. See License.txt in the project root for license information.`,
|
|
||||||
` *--------------------------------------------------------------------------------------------*/`
|
|
||||||
].join('\n');
|
|
||||||
return convertTabsToSpaces(getNewFileHeader(tag) + content.slice(oldheader.length));
|
|
||||||
}
|
|
||||||
function getNewFileHeader(tag) {
|
|
||||||
const [major, minor] = tag.split('.');
|
|
||||||
const shorttag = `${major}.${minor}`;
|
|
||||||
const header = [
|
|
||||||
`// Type definitions for Visual Studio Code ${shorttag}`,
|
|
||||||
`// Project: https://github.com/microsoft/vscode`,
|
|
||||||
`// Definitions by: Visual Studio Code Team, Microsoft <https://github.com/Microsoft>`,
|
|
||||||
`// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped`,
|
|
||||||
``,
|
|
||||||
`/*---------------------------------------------------------------------------------------------`,
|
|
||||||
` * Copyright (c) Microsoft Corporation. All rights reserved.`,
|
|
||||||
` * Licensed under the Source EULA.`,
|
|
||||||
` * See https://github.com/Microsoft/vscode/blob/master/LICENSE.txt for license information.`,
|
|
||||||
` *--------------------------------------------------------------------------------------------*/`,
|
|
||||||
``,
|
|
||||||
`/**`,
|
|
||||||
` * Type Definition for Visual Studio Code ${shorttag} Extension API`,
|
|
||||||
` * See https://code.visualstudio.com/api for more information`,
|
|
||||||
` */`
|
|
||||||
].join('\n');
|
|
||||||
return header;
|
|
||||||
}
|
|
||||||
@@ -1,13 +1,13 @@
|
|||||||
resources:
|
resources:
|
||||||
containers:
|
containers:
|
||||||
- container: linux-x64
|
- container: linux-x64
|
||||||
image: sqltoolscontainers.azurecr.io/linux-build-agent:3
|
image: sqltoolscontainers.azurecr.io/linux-build-agent:2
|
||||||
endpoint: ContainerRegistry
|
endpoint: ContainerRegistry
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
- job: Compile
|
- job: Compile
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'Ubuntu-18.04'
|
vmImage: 'Ubuntu-16.04'
|
||||||
container: linux-x64
|
container: linux-x64
|
||||||
steps:
|
steps:
|
||||||
- script: |
|
- script: |
|
||||||
@@ -15,7 +15,6 @@ jobs:
|
|||||||
echo "##vso[build.addbuildtag]$(VSCODE_QUALITY)"
|
echo "##vso[build.addbuildtag]$(VSCODE_QUALITY)"
|
||||||
displayName: Add Quality Build Tag
|
displayName: Add Quality Build Tag
|
||||||
- template: sql-product-compile.yml
|
- template: sql-product-compile.yml
|
||||||
timeoutInMinutes: 90
|
|
||||||
|
|
||||||
- job: macOS
|
- job: macOS
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_BUILD_MACOS'], 'true'), ne(variables['VSCODE_QUALITY'], 'saw'))
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_MACOS'], 'true'), ne(variables['VSCODE_QUALITY'], 'saw'))
|
||||||
@@ -25,7 +24,7 @@ jobs:
|
|||||||
- Compile
|
- Compile
|
||||||
steps:
|
steps:
|
||||||
- template: darwin/sql-product-build-darwin.yml
|
- template: darwin/sql-product-build-darwin.yml
|
||||||
timeoutInMinutes: 90
|
timeoutInMinutes: 180
|
||||||
|
|
||||||
- job: macOS_Signing
|
- job: macOS_Signing
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_BUILD_MACOS'], 'true'), eq(variables['signed'], true), ne(variables['VSCODE_QUALITY'], 'saw'))
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_MACOS'], 'true'), eq(variables['signed'], true), ne(variables['VSCODE_QUALITY'], 'saw'))
|
||||||
@@ -40,7 +39,7 @@ jobs:
|
|||||||
- job: Linux
|
- job: Linux
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX'], 'true'))
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_LINUX'], 'true'))
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'Ubuntu-18.04'
|
vmImage: 'Ubuntu-16.04'
|
||||||
container: linux-x64
|
container: linux-x64
|
||||||
dependsOn:
|
dependsOn:
|
||||||
- Compile
|
- Compile
|
||||||
@@ -48,12 +47,12 @@ jobs:
|
|||||||
- template: linux/sql-product-build-linux.yml
|
- template: linux/sql-product-build-linux.yml
|
||||||
parameters:
|
parameters:
|
||||||
extensionsToUnitTest: ["admin-tool-ext-win", "agent", "azdata", "azurecore", "cms", "dacpac", "import", "schema-compare", "notebook", "resource-deployment", "machine-learning", "sql-database-projects", "data-workspace"]
|
extensionsToUnitTest: ["admin-tool-ext-win", "agent", "azdata", "azurecore", "cms", "dacpac", "import", "schema-compare", "notebook", "resource-deployment", "machine-learning", "sql-database-projects", "data-workspace"]
|
||||||
timeoutInMinutes: 90
|
timeoutInMinutes: 70
|
||||||
|
|
||||||
- job: LinuxWeb
|
- job: LinuxWeb
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WEB'], 'true'), ne(variables['VSCODE_QUALITY'], 'saw'))
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WEB'], 'true'), ne(variables['VSCODE_QUALITY'], 'saw'))
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'Ubuntu-18.04'
|
vmImage: 'Ubuntu-16.04'
|
||||||
container: linux-x64
|
container: linux-x64
|
||||||
variables:
|
variables:
|
||||||
VSCODE_ARCH: x64
|
VSCODE_ARCH: x64
|
||||||
@@ -61,18 +60,16 @@ jobs:
|
|||||||
- Compile
|
- Compile
|
||||||
steps:
|
steps:
|
||||||
- template: web/sql-product-build-web.yml
|
- template: web/sql-product-build-web.yml
|
||||||
timeoutInMinutes: 90
|
|
||||||
|
|
||||||
- job: Docker
|
# - job: Docker
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_BUILD_DOCKER'], 'true'))
|
# condition: and(succeeded(), eq(variables['VSCODE_BUILD_DOCKER'], 'true'))
|
||||||
pool:
|
# pool:
|
||||||
vmImage: 'Ubuntu-18.04'
|
# vmImage: 'Ubuntu-16.04'
|
||||||
container: linux-x64
|
# container: linux-x64
|
||||||
dependsOn:
|
# dependsOn:
|
||||||
- Linux
|
# - Linux
|
||||||
steps:
|
# steps:
|
||||||
- template: docker/sql-product-build-docker.yml
|
# - template: docker/sql-product-build-docker.yml
|
||||||
timeoutInMinutes: 90
|
|
||||||
|
|
||||||
- job: Windows
|
- job: Windows
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WIN32'], 'true'))
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WIN32'], 'true'))
|
||||||
@@ -82,7 +79,7 @@ jobs:
|
|||||||
- Compile
|
- Compile
|
||||||
steps:
|
steps:
|
||||||
- template: win32/sql-product-build-win32.yml
|
- template: win32/sql-product-build-win32.yml
|
||||||
timeoutInMinutes: 90
|
timeoutInMinutes: 70
|
||||||
|
|
||||||
- job: Windows_Test
|
- job: Windows_Test
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WIN32'], 'true'))
|
condition: and(succeeded(), eq(variables['VSCODE_BUILD_WIN32'], 'true'))
|
||||||
@@ -93,12 +90,11 @@ jobs:
|
|||||||
- Windows
|
- Windows
|
||||||
steps:
|
steps:
|
||||||
- template: win32/sql-product-test-win32.yml
|
- template: win32/sql-product-test-win32.yml
|
||||||
timeoutInMinutes: 90
|
|
||||||
|
|
||||||
- job: Release
|
- job: Release
|
||||||
condition: and(succeeded(), or(eq(variables['VSCODE_RELEASE'], 'true'), and(eq(variables['VSCODE_QUALITY'], 'insider'), eq(variables['Build.Reason'], 'Schedule'))))
|
condition: and(succeeded(), or(eq(variables['VSCODE_RELEASE'], 'true'), and(eq(variables['VSCODE_QUALITY'], 'insider'), eq(variables['Build.Reason'], 'Schedule'))))
|
||||||
pool:
|
pool:
|
||||||
vmImage: 'Ubuntu-18.04'
|
vmImage: 'Ubuntu-16.04'
|
||||||
dependsOn:
|
dependsOn:
|
||||||
- macOS
|
- macOS
|
||||||
- Linux
|
- Linux
|
||||||
|
|||||||
@@ -1,4 +1,19 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
displayName: Prepare cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
displayName: Restore Cache - Compiled Files
|
||||||
|
inputs:
|
||||||
|
keyfile: 'build/.cachesalt, .build/commit, .build/quality'
|
||||||
|
targetfolder: '.build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min'
|
||||||
|
vstsFeed: 'BuildCache'
|
||||||
|
platformIndependent: true
|
||||||
|
alias: 'Compilation'
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.13.0"
|
versionSpec: "12.13.0"
|
||||||
@@ -12,6 +27,7 @@ steps:
|
|||||||
inputs:
|
inputs:
|
||||||
azureSubscription: 'ClientToolsInfra_670062 (88d5392f-a34f-4769-b405-f597fc533613)'
|
azureSubscription: 'ClientToolsInfra_670062 (88d5392f-a34f-4769-b405-f597fc533613)'
|
||||||
KeyVaultName: ado-secrets
|
KeyVaultName: ado-secrets
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -24,6 +40,7 @@ steps:
|
|||||||
git config user.email "sqltools@service.microsoft.com"
|
git config user.email "sqltools@service.microsoft.com"
|
||||||
git config user.name "AzureDataStudio"
|
git config user.name "AzureDataStudio"
|
||||||
displayName: Prepare tooling
|
displayName: Prepare tooling
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -31,44 +48,34 @@ steps:
|
|||||||
git fetch distro
|
git fetch distro
|
||||||
git merge $(node -p "require('./package.json').distro")
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
mkdir -p .build
|
|
||||||
node build/azure-pipelines/common/sql-computeNodeModulesCacheKey.js > .build/yarnlockhash
|
|
||||||
displayName: Prepare yarn cache key
|
|
||||||
|
|
||||||
- task: Cache@2
|
|
||||||
inputs:
|
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
|
||||||
path: .build/node_modules_cache
|
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
|
||||||
displayName: Restore Cache - Node Modules
|
displayName: Restore Cache - Node Modules
|
||||||
|
inputs:
|
||||||
- script: |
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
set -e
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
tar -xzf .build/node_modules_cache/cache.tgz
|
vstsFeed: 'BuildCache'
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules archive
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
CHILD_CONCURRENCY=1 yarn --frozen-lockfile
|
CHILD_CONCURRENCY=1 yarn --frozen-lockfile
|
||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
condition: and(succeeded(), ne(variables['NODE_MODULES_RESTORED'], 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
set -e
|
displayName: Save Cache - Node Modules
|
||||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
inputs:
|
||||||
mkdir -p .build/node_modules_cache
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
tar -czf .build/node_modules_cache/cache.tgz --files-from .build/node_modules_list.txt
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
vstsFeed: 'BuildCache'
|
||||||
displayName: Create node_modules archive
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
yarn postinstall
|
yarn postinstall
|
||||||
displayName: Run postinstall scripts
|
displayName: Run postinstall scripts
|
||||||
condition: and(succeeded(), eq(variables['NODE_MODULES_RESTORED'], 'true'))
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
# Mixin must run before optimize, because the CSS loader will
|
# Mixin must run before optimize, because the CSS loader will
|
||||||
# inline small SVGs
|
# inline small SVGs
|
||||||
@@ -76,6 +83,7 @@ steps:
|
|||||||
set -e
|
set -e
|
||||||
node build/azure-pipelines/mixin
|
node build/azure-pipelines/mixin
|
||||||
displayName: Mix in quality
|
displayName: Mix in quality
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -84,7 +92,7 @@ steps:
|
|||||||
yarn strict-vscode
|
yarn strict-vscode
|
||||||
yarn valid-layers-check
|
yarn valid-layers-check
|
||||||
displayName: Run hygiene, eslint
|
displayName: Run hygiene, eslint
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'), eq(variables['VSCODE_STEP_ON_IT'], 'false'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -94,6 +102,7 @@ steps:
|
|||||||
yarn gulp vscode-reh-linux-x64-min
|
yarn gulp vscode-reh-linux-x64-min
|
||||||
yarn gulp vscode-reh-web-linux-x64-min
|
yarn gulp vscode-reh-web-linux-x64-min
|
||||||
displayName: Compile
|
displayName: Compile
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -101,6 +110,7 @@ steps:
|
|||||||
AZURE_STORAGE_ACCESS_KEY="$(sourcemap-storage-key)" \
|
AZURE_STORAGE_ACCESS_KEY="$(sourcemap-storage-key)" \
|
||||||
node build/azure-pipelines/upload-sourcemaps
|
node build/azure-pipelines/upload-sourcemaps
|
||||||
displayName: Upload sourcemaps
|
displayName: Upload sourcemaps
|
||||||
|
condition: and(succeeded(), ne(variables['CacheExists-Compilation'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -115,13 +125,12 @@ steps:
|
|||||||
- task: PublishBuildArtifacts@1
|
- task: PublishBuildArtifacts@1
|
||||||
displayName: 'Publish Artifact: drop'
|
displayName: 'Publish Artifact: drop'
|
||||||
|
|
||||||
- script: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
set -e
|
displayName: Save Cache - Compiled Files
|
||||||
tar -czf $(Build.ArtifactStagingDirectory)/compilation.tar.gz .build out-*
|
|
||||||
displayName: Compress compilation artifact
|
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@1
|
|
||||||
inputs:
|
inputs:
|
||||||
targetPath: $(Build.ArtifactStagingDirectory)/compilation.tar.gz
|
keyfile: 'build/.cachesalt, .build/commit, .build/quality'
|
||||||
artifactName: Compilation
|
targetfolder: '.build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min'
|
||||||
displayName: Publish compilation artifact
|
vstsFeed: 'BuildCache'
|
||||||
|
platformIndependent: true
|
||||||
|
alias: 'Compilation'
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
steps:
|
steps:
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
|
|||||||
@@ -1,7 +1,28 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
echo -n $ENABLE_TERRAPIN > .build/terrapin
|
||||||
|
displayName: Prepare compilation cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: "build/.cachesalt, .build/commit, .build/quality, .build/terrapin"
|
||||||
|
targetfolder: ".build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
platformIndependent: true
|
||||||
|
alias: "Compilation"
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
@@ -13,17 +34,6 @@ steps:
|
|||||||
azureSubscription: "vscode-builds-subscription"
|
azureSubscription: "vscode-builds-subscription"
|
||||||
KeyVaultName: vscode
|
KeyVaultName: vscode
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
path: $(Build.ArtifactStagingDirectory)
|
|
||||||
displayName: Download compilation output
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf $(Build.ArtifactStagingDirectory)/compilation.tar.gz
|
|
||||||
displayName: Extract compilation output
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
cat << EOF > ~/.netrc
|
cat << EOF > ~/.netrc
|
||||||
@@ -38,35 +48,30 @@ steps:
|
|||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
git pull --no-rebase https://github.com/$(VSCODE_MIXIN_REPO).git $(node -p "require('./package.json').distro")
|
git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git"
|
||||||
|
git fetch distro
|
||||||
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- script: |
|
|
||||||
mkdir -p .build
|
|
||||||
node build/azure-pipelines/common/computeNodeModulesCacheKey.js "web" $ENABLE_TERRAPIN > .build/yarnlockhash
|
|
||||||
displayName: Prepare yarn cache flags
|
|
||||||
|
|
||||||
- task: Cache@2
|
|
||||||
inputs:
|
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
|
||||||
path: .build/node_modules_cache
|
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
|
||||||
displayName: Restore node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf .build/node_modules_cache/cache.tgz
|
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
npx https://aka.ms/enablesecurefeed standAlone
|
npx https://aka.ms/enablesecurefeed standAlone
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
|
||||||
displayName: Switch to Terrapin packages
|
displayName: Switch to Terrapin packages
|
||||||
|
timeoutInMinutes: 5
|
||||||
|
condition: and(succeeded(), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
echo -n "web" > .build/arch
|
||||||
|
displayName: Prepare yarn cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
|
export CHILD_CONCURRENCY="1"
|
||||||
for i in {1..3}; do # try 3 times, for Terrapin
|
for i in {1..3}; do # try 3 times, for Terrapin
|
||||||
yarn --frozen-lockfile && break
|
yarn --frozen-lockfile && break
|
||||||
if [ $i -eq 3 ]; then
|
if [ $i -eq 3 ]; then
|
||||||
@@ -75,19 +80,21 @@ steps:
|
|||||||
fi
|
fi
|
||||||
echo "Yarn failed $i, trying again..."
|
echo "Yarn failed $i, trying again..."
|
||||||
done
|
done
|
||||||
env:
|
|
||||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
|
||||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
|
||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt
|
yarn postinstall
|
||||||
mkdir -p .build/node_modules_cache
|
displayName: Run postinstall scripts
|
||||||
tar -czf .build/node_modules_cache/cache.tgz --files-from .build/node_modules_list.txt
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Create node_modules archive
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
@@ -123,8 +130,3 @@ steps:
|
|||||||
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
./build/azure-pipelines/web/publish.sh
|
./build/azure-pipelines/web/publish.sh
|
||||||
displayName: Publish
|
displayName: Publish
|
||||||
|
|
||||||
- publish: $(Agent.BuildDirectory)/vscode-web.tar.gz
|
|
||||||
artifact: vscode-web-standalone
|
|
||||||
displayName: Publish web archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|||||||
@@ -1,5 +1,25 @@
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
- script: |
|
||||||
|
mkdir -p .build
|
||||||
|
echo -n $BUILD_SOURCEVERSION > .build/commit
|
||||||
|
echo -n $VSCODE_QUALITY > .build/quality
|
||||||
|
displayName: Prepare cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
displayName: Restore Cache - Compiled Files
|
||||||
|
inputs:
|
||||||
|
keyfile: 'build/.cachesalt, .build/commit, .build/quality'
|
||||||
|
targetfolder: '.build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min'
|
||||||
|
vstsFeed: 'BuildCache'
|
||||||
|
platformIndependent: true
|
||||||
|
alias: 'Compilation'
|
||||||
|
|
||||||
|
- script: |
|
||||||
|
set -e
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.13.0"
|
versionSpec: "12.13.0"
|
||||||
@@ -15,16 +35,6 @@ steps:
|
|||||||
KeyVaultName: ado-secrets
|
KeyVaultName: ado-secrets
|
||||||
SecretsFilter: 'github-distro-mixin-password'
|
SecretsFilter: 'github-distro-mixin-password'
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
displayName: Download compilation output
|
|
||||||
|
|
||||||
- script: |
|
|
||||||
set -e
|
|
||||||
tar -xzf $(Pipeline.Workspace)/compilation.tar.gz
|
|
||||||
displayName: Extract compilation output
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
set -e
|
set -e
|
||||||
cat << EOF > ~/.netrc
|
cat << EOF > ~/.netrc
|
||||||
@@ -99,4 +109,3 @@ steps:
|
|||||||
# VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
# VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)" \
|
||||||
# ./build/azure-pipelines/web/publish.sh
|
# ./build/azure-pipelines/web/publish.sh
|
||||||
# displayName: Publish
|
# displayName: Publish
|
||||||
|
|
||||||
|
|||||||
@@ -1,10 +1,7 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<configuration>
|
<configuration>
|
||||||
<packageSources>
|
<packageSources>
|
||||||
<clear />
|
<clear/>
|
||||||
<add key="ESRP" value="https://microsoft.pkgs.visualstudio.com/_packaging/ESRP/nuget/v3/index.json" />
|
<add key="ESRP" value="https://microsoft.pkgs.visualstudio.com/_packaging/ESRP/nuget/v3/index.json" />
|
||||||
</packageSources>
|
</packageSources>
|
||||||
<disabledPackageSources>
|
|
||||||
<clear />
|
|
||||||
</disabledPackageSources>
|
|
||||||
</configuration>
|
</configuration>
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
steps:
|
steps:
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@3 # {{SQL CARBON EDIT}} update version
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@3 # {{SQL CARBON EDIT}} update version
|
||||||
inputs:
|
inputs:
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ $ErrorActionPreference = "Stop"
|
|||||||
|
|
||||||
$CertBytes = [System.Convert]::FromBase64String($CertBase64)
|
$CertBytes = [System.Convert]::FromBase64String($CertBase64)
|
||||||
$CertCollection = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2Collection
|
$CertCollection = New-Object System.Security.Cryptography.X509Certificates.X509Certificate2Collection
|
||||||
$CertCollection.Import($CertBytes, $null, [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::Exportable -bxor [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::PersistKeySet)
|
$CertCollection.Import($CertBytes, $null, [System.Security.Cryptography.X509Certificates.X509KeyStorageFlags]::Exportable)
|
||||||
|
|
||||||
$CertStore = New-Object System.Security.Cryptography.X509Certificates.X509Store("My","LocalMachine")
|
$CertStore = New-Object System.Security.Cryptography.X509Certificates.X509Store("My","LocalMachine")
|
||||||
$CertStore.Open("ReadWrite")
|
$CertStore.Open("ReadWrite")
|
||||||
|
|||||||
@@ -1,7 +1,28 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- powershell: |
|
||||||
|
mkdir .build -ea 0
|
||||||
|
"$env:BUILD_SOURCEVERSION" | Out-File -Encoding ascii -NoNewLine .build\commit
|
||||||
|
"$env:VSCODE_QUALITY" | Out-File -Encoding ascii -NoNewLine .build\quality
|
||||||
|
"$env:ENABLE_TERRAPIN" | Out-File -Encoding ascii -NoNewLine .build\terrapin
|
||||||
|
displayName: Prepare compilation cache flags
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: "build/.cachesalt, .build/commit, .build/quality, .build/terrapin"
|
||||||
|
targetfolder: ".build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
platformIndependent: true
|
||||||
|
alias: "Compilation"
|
||||||
|
|
||||||
|
- powershell: |
|
||||||
|
$ErrorActionPreference = "Stop"
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.18.3"
|
versionSpec: "12.14.1"
|
||||||
|
|
||||||
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
- task: geeklearningio.gl-vsts-tasks-yarn.yarn-installer-task.YarnInstaller@2
|
||||||
inputs:
|
inputs:
|
||||||
@@ -18,18 +39,6 @@ steps:
|
|||||||
azureSubscription: "vscode-builds-subscription"
|
azureSubscription: "vscode-builds-subscription"
|
||||||
KeyVaultName: vscode
|
KeyVaultName: vscode
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
path: $(Build.ArtifactStagingDirectory)
|
|
||||||
displayName: Download compilation output
|
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
exec { tar --force-local -xzf $(Build.ArtifactStagingDirectory)/compilation.tar.gz }
|
|
||||||
displayName: Extract compilation output
|
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
@@ -42,34 +51,26 @@ steps:
|
|||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { git pull --no-rebase https://github.com/$(VSCODE_MIXIN_REPO).git $(node -p "require('./package.json').distro") }
|
exec { git remote add distro "https://github.com/$(VSCODE_MIXIN_REPO).git" }
|
||||||
|
exec { git fetch distro }
|
||||||
|
exec { git merge $(node -p "require('./package.json').distro") }
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
"$(VSCODE_ARCH)" | Out-File -Encoding ascii -NoNewLine .build\arch
|
|
||||||
"$env:ENABLE_TERRAPIN" | Out-File -Encoding ascii -NoNewLine .build\terrapin
|
|
||||||
node build/azure-pipelines/common/computeNodeModulesCacheKey.js > .build/yarnlockhash
|
|
||||||
displayName: Prepare yarn cache flags
|
|
||||||
|
|
||||||
- task: Cache@2
|
|
||||||
inputs:
|
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/arch, .build/terrapin, .build/yarnlockhash'
|
|
||||||
path: .build/node_modules_cache
|
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
|
||||||
displayName: Restore node_modules cache
|
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
exec { 7z.exe x .build/node_modules_cache/cache.7z -aos }
|
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules cache
|
|
||||||
|
|
||||||
- script: |
|
- script: |
|
||||||
npx https://aka.ms/enablesecurefeed standAlone
|
npx https://aka.ms/enablesecurefeed standAlone
|
||||||
timeoutInMinutes: 5
|
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
|
||||||
displayName: Switch to Terrapin packages
|
displayName: Switch to Terrapin packages
|
||||||
|
timeoutInMinutes: 5
|
||||||
|
condition: and(succeeded(), eq(variables['ENABLE_TERRAPIN'], 'true'))
|
||||||
|
|
||||||
|
- powershell: |
|
||||||
|
"$(VSCODE_ARCH)" | Out-File -Encoding ascii -NoNewLine .build\arch
|
||||||
|
displayName: Prepare yarn cache flags
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
@@ -78,20 +79,22 @@ steps:
|
|||||||
$env:npm_config_arch="$(VSCODE_ARCH)"
|
$env:npm_config_arch="$(VSCODE_ARCH)"
|
||||||
$env:CHILD_CONCURRENCY="1"
|
$env:CHILD_CONCURRENCY="1"
|
||||||
retry { exec { yarn --frozen-lockfile } }
|
retry { exec { yarn --frozen-lockfile } }
|
||||||
env:
|
|
||||||
ELECTRON_SKIP_BINARY_DOWNLOAD: 1
|
|
||||||
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
|
|
||||||
displayName: Install dependencies
|
displayName: Install dependencies
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
|
inputs:
|
||||||
|
keyfile: ".build/arch, .build/terrapin, build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock"
|
||||||
|
targetfolder: "**/node_modules, !**/node_modules/**/node_modules"
|
||||||
|
vstsFeed: "npm-vscode"
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt }
|
exec { yarn postinstall }
|
||||||
exec { mkdir -Force .build/node_modules_cache }
|
displayName: Run postinstall scripts
|
||||||
exec { 7z.exe a .build/node_modules_cache/cache.7z -mx3 `@.build/node_modules_list.txt }
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Create node_modules archive
|
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
@@ -104,17 +107,10 @@ steps:
|
|||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
$env:VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)"
|
$env:VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)"
|
||||||
exec { yarn gulp "vscode-win32-$(VSCODE_ARCH)-min-ci" }
|
exec { yarn gulp "vscode-win32-$(VSCODE_ARCH)-min-ci" }
|
||||||
echo "##vso[task.setvariable variable=CodeSigningFolderPath]$(agent.builddirectory)/VSCode-win32-$(VSCODE_ARCH)"
|
|
||||||
displayName: Build
|
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
$env:VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)"
|
|
||||||
exec { yarn gulp "vscode-win32-$(VSCODE_ARCH)-code-helper" }
|
exec { yarn gulp "vscode-win32-$(VSCODE_ARCH)-code-helper" }
|
||||||
exec { yarn gulp "vscode-win32-$(VSCODE_ARCH)-inno-updater" }
|
exec { yarn gulp "vscode-win32-$(VSCODE_ARCH)-inno-updater" }
|
||||||
displayName: Prepare Package
|
echo "##vso[task.setvariable variable=CodeSigningFolderPath]$(agent.builddirectory)/VSCode-win32-$(VSCODE_ARCH)"
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
displayName: Build
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
@@ -126,21 +122,12 @@ steps:
|
|||||||
displayName: Build Server
|
displayName: Build Server
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
$env:VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)"
|
|
||||||
exec { yarn npm-run-all -lp "electron $(VSCODE_ARCH)" "playwright-install" }
|
|
||||||
displayName: Download Electron and Playwright
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { yarn electron $(VSCODE_ARCH) }
|
exec { yarn electron $(VSCODE_ARCH) }
|
||||||
exec { .\scripts\test.bat --build --tfs "Unit Tests" }
|
exec { .\scripts\test.bat --build --tfs "Unit Tests" }
|
||||||
displayName: Run unit tests (Electron)
|
displayName: Run unit tests (Electron)
|
||||||
timeoutInMinutes: 7
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
@@ -148,14 +135,6 @@ steps:
|
|||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { yarn test-browser --build --browser chromium --browser firefox --tfs "Browser Unit Tests" }
|
exec { yarn test-browser --build --browser chromium --browser firefox --tfs "Browser Unit Tests" }
|
||||||
displayName: Run unit tests (Browser)
|
displayName: Run unit tests (Browser)
|
||||||
timeoutInMinutes: 7
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
exec { yarn --cwd test/integration/browser compile }
|
|
||||||
displayName: Compile integration tests
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
@@ -169,7 +148,6 @@ steps:
|
|||||||
$AppNameShort = $AppProductJson.nameShort
|
$AppNameShort = $AppProductJson.nameShort
|
||||||
exec { $env:INTEGRATION_TEST_ELECTRON_PATH = "$AppRoot\$AppNameShort.exe"; $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-win32-$(VSCODE_ARCH)"; .\scripts\test-integration.bat --build --tfs "Integration Tests" }
|
exec { $env:INTEGRATION_TEST_ELECTRON_PATH = "$AppRoot\$AppNameShort.exe"; $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-win32-$(VSCODE_ARCH)"; .\scripts\test-integration.bat --build --tfs "Integration Tests" }
|
||||||
displayName: Run integration tests (Electron)
|
displayName: Run integration tests (Electron)
|
||||||
timeoutInMinutes: 10
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
@@ -177,7 +155,6 @@ steps:
|
|||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-web-win32-$(VSCODE_ARCH)"; .\resources\server\test\test-web-integration.bat --browser firefox }
|
exec { $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-web-win32-$(VSCODE_ARCH)"; .\resources\server\test\test-web-integration.bat --browser firefox }
|
||||||
displayName: Run integration tests (Browser)
|
displayName: Run integration tests (Browser)
|
||||||
timeoutInMinutes: 7
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
@@ -188,7 +165,6 @@ steps:
|
|||||||
$AppNameShort = $AppProductJson.nameShort
|
$AppNameShort = $AppProductJson.nameShort
|
||||||
exec { $env:INTEGRATION_TEST_ELECTRON_PATH = "$AppRoot\$AppNameShort.exe"; $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-win32-$(VSCODE_ARCH)"; .\resources\server\test\test-remote-integration.bat }
|
exec { $env:INTEGRATION_TEST_ELECTRON_PATH = "$AppRoot\$AppNameShort.exe"; $env:VSCODE_REMOTE_SERVER_PATH = "$(agent.builddirectory)\vscode-reh-win32-$(VSCODE_ARCH)"; .\resources\server\test\test-remote-integration.bat }
|
||||||
displayName: Run remote integration tests (Electron)
|
displayName: Run remote integration tests (Electron)
|
||||||
timeoutInMinutes: 7
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeeded(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|
||||||
- task: PublishPipelineArtifact@0
|
- task: PublishPipelineArtifact@0
|
||||||
@@ -204,7 +180,7 @@ steps:
|
|||||||
inputs:
|
inputs:
|
||||||
testResultsFiles: "*-results.xml"
|
testResultsFiles: "*-results.xml"
|
||||||
searchFolder: "$(Build.ArtifactStagingDirectory)/test-results"
|
searchFolder: "$(Build.ArtifactStagingDirectory)/test-results"
|
||||||
condition: and(succeededOrFailed(), eq(variables['VSCODE_STEP_ON_IT'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
condition: and(succeededOrFailed(), ne(variables['VSCODE_ARCH'], 'arm64'))
|
||||||
|
|
||||||
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
|
||||||
inputs:
|
inputs:
|
||||||
@@ -260,7 +236,6 @@ steps:
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
SessionTimeout: 120
|
SessionTimeout: 120
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: NuGetCommand@2
|
- task: NuGetCommand@2
|
||||||
displayName: Install ESRPClient.exe
|
displayName: Install ESRPClient.exe
|
||||||
@@ -270,13 +245,11 @@ steps:
|
|||||||
nugetConfigPath: 'build\azure-pipelines\win32\ESRPClient\NuGet.config'
|
nugetConfigPath: 'build\azure-pipelines\win32\ESRPClient\NuGet.config'
|
||||||
externalFeedCredentials: "ESRP Nuget"
|
externalFeedCredentials: "ESRP Nuget"
|
||||||
restoreDirectory: packages
|
restoreDirectory: packages
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: ESRPImportCertTask@1
|
- task: ESRPImportCertTask@1
|
||||||
displayName: Import ESRP Request Signing Certificate
|
displayName: Import ESRP Request Signing Certificate
|
||||||
inputs:
|
inputs:
|
||||||
ESRP: "ESRP CodeSign"
|
ESRP: "ESRP CodeSign"
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- task: PowerShell@2
|
- task: PowerShell@2
|
||||||
inputs:
|
inputs:
|
||||||
@@ -284,7 +257,6 @@ steps:
|
|||||||
filePath: .\build\azure-pipelines\win32\import-esrp-auth-cert.ps1
|
filePath: .\build\azure-pipelines\win32\import-esrp-auth-cert.ps1
|
||||||
arguments: "$(ESRP-SSL-AADAuth)"
|
arguments: "$(ESRP-SSL-AADAuth)"
|
||||||
displayName: Import ESRP Auth Certificate
|
displayName: Import ESRP Auth Certificate
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
@@ -294,32 +266,6 @@ steps:
|
|||||||
$env:VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)"
|
$env:VSCODE_MIXIN_PASSWORD="$(github-distro-mixin-password)"
|
||||||
.\build\azure-pipelines\win32\publish.ps1
|
.\build\azure-pipelines\win32\publish.ps1
|
||||||
displayName: Publish
|
displayName: Publish
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(System.DefaultWorkingDirectory)\.build\win32-$(VSCODE_ARCH)\archive\VSCode-win32-$(VSCODE_ARCH).zip
|
|
||||||
artifact: vscode-win32-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(System.DefaultWorkingDirectory)\.build\win32-$(VSCODE_ARCH)\system-setup\VSCodeSetup.exe
|
|
||||||
artifact: vscode-win32-$(VSCODE_ARCH)-setup
|
|
||||||
displayName: Publish system setup
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(System.DefaultWorkingDirectory)\.build\win32-$(VSCODE_ARCH)\user-setup\VSCodeSetup.exe
|
|
||||||
artifact: vscode-win32-$(VSCODE_ARCH)-user-setup
|
|
||||||
displayName: Publish user setup
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'))
|
|
||||||
|
|
||||||
- publish: $(System.DefaultWorkingDirectory)\.build\vscode-server-win32-$(VSCODE_ARCH).zip
|
|
||||||
artifact: vscode-server-win32-$(VSCODE_ARCH)
|
|
||||||
displayName: Publish server archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
|
||||||
|
|
||||||
- publish: $(System.DefaultWorkingDirectory)\.build\vscode-server-win32-$(VSCODE_ARCH)-web.zip
|
|
||||||
artifact: vscode-server-win32-$(VSCODE_ARCH)-web
|
|
||||||
displayName: Publish web server archive
|
|
||||||
condition: and(succeeded(), ne(variables['VSCODE_PUBLISH'], 'false'), ne(variables['VSCODE_ARCH'], 'arm64'))
|
|
||||||
|
|
||||||
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
- task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0
|
||||||
displayName: "Component Detection"
|
displayName: "Component Detection"
|
||||||
|
|||||||
@@ -1,4 +1,25 @@
|
|||||||
steps:
|
steps:
|
||||||
|
- powershell: |
|
||||||
|
mkdir .build -ea 0
|
||||||
|
"$env:BUILD_SOURCEVERSION" | Out-File -Encoding ascii -NoNewLine .build\commit
|
||||||
|
"$env:VSCODE_QUALITY" | Out-File -Encoding ascii -NoNewLine .build\quality
|
||||||
|
displayName: Prepare cache flag
|
||||||
|
|
||||||
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
|
displayName: Restore Cache - Compiled Files
|
||||||
|
inputs:
|
||||||
|
keyfile: 'build/.cachesalt, .build/commit, .build/quality'
|
||||||
|
targetfolder: '.build, out-build, out-vscode-min, out-vscode-reh-min, out-vscode-reh-web-min'
|
||||||
|
vstsFeed: 'BuildCache'
|
||||||
|
platformIndependent: true
|
||||||
|
alias: 'Compilation'
|
||||||
|
|
||||||
|
- powershell: |
|
||||||
|
$ErrorActionPreference = "Stop"
|
||||||
|
exit 1
|
||||||
|
displayName: Check RestoreCache
|
||||||
|
condition: and(succeeded(), ne(variables['CacheRestored-Compilation'], 'true'))
|
||||||
|
|
||||||
- task: NodeTool@0
|
- task: NodeTool@0
|
||||||
inputs:
|
inputs:
|
||||||
versionSpec: "12.13.0"
|
versionSpec: "12.13.0"
|
||||||
@@ -13,22 +34,11 @@ steps:
|
|||||||
addToPath: true
|
addToPath: true
|
||||||
|
|
||||||
- task: AzureKeyVault@1
|
- task: AzureKeyVault@1
|
||||||
|
displayName: 'Azure Key Vault: Get Secrets'
|
||||||
inputs:
|
inputs:
|
||||||
azureSubscription: 'ClientToolsInfra_670062 (88d5392f-a34f-4769-b405-f597fc533613)'
|
azureSubscription: 'ClientToolsInfra_670062 (88d5392f-a34f-4769-b405-f597fc533613)'
|
||||||
KeyVaultName: ado-secrets
|
KeyVaultName: ado-secrets
|
||||||
SecretsFilter: 'github-distro-mixin-password,standalone-extensions-uri'
|
SecretsFilter: 'github-distro-mixin-password'
|
||||||
displayName: 'Azure Key Vault: Get Secrets'
|
|
||||||
|
|
||||||
- task: DownloadPipelineArtifact@2
|
|
||||||
inputs:
|
|
||||||
artifact: Compilation
|
|
||||||
displayName: Download compilation output
|
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
exec { tar --force-local -xzf $(Pipeline.Workspace)/compilation.tar.gz }
|
|
||||||
displayName: Extract compilation output
|
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
@@ -45,51 +55,37 @@ steps:
|
|||||||
git merge $(node -p "require('./package.json').distro")
|
git merge $(node -p "require('./package.json').distro")
|
||||||
displayName: Merge distro
|
displayName: Merge distro
|
||||||
|
|
||||||
- powershell: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.RestoreCacheV1.RestoreCache@1
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
exec { node build/azure-pipelines/common/sql-computeNodeModulesCacheKey.js > .build/yarnlockhash }
|
|
||||||
displayName: Prepare yarn cache key
|
|
||||||
|
|
||||||
- task: Cache@2
|
|
||||||
inputs:
|
|
||||||
key: 'nodeModules | $(Agent.OS) | .build/yarnlockhash'
|
|
||||||
path: .build/node_modules_cache
|
|
||||||
cacheHitVar: NODE_MODULES_RESTORED
|
|
||||||
displayName: Restore Cache - Node Modules
|
displayName: Restore Cache - Node Modules
|
||||||
|
inputs:
|
||||||
- powershell: |
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
$ErrorActionPreference = "Stop"
|
vstsFeed: 'BuildCache'
|
||||||
exec { 7z.exe x .build/node_modules_cache/cache.7z -aos }
|
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
|
||||||
displayName: Extract node_modules archive
|
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
$env:CHILD_CONCURRENCY="1"
|
$env:CHILD_CONCURRENCY="1"
|
||||||
exec { yarn --frozen-lockfile }
|
exec { yarn --frozen-lockfile }
|
||||||
|
displayName: Install dependencies
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: $(github-distro-mixin-password)
|
GITHUB_TOKEN: $(github-distro-mixin-password)
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
displayName: Install dependencies
|
|
||||||
|
|
||||||
- powershell: |
|
- task: 1ESLighthouseEng.PipelineArtifactCaching.SaveCacheV1.SaveCache@1
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
displayName: Save Cache - Node Modules
|
||||||
$ErrorActionPreference = "Stop"
|
inputs:
|
||||||
exec { node build/azure-pipelines/common/listNodeModules.js .build/node_modules_list.txt }
|
keyfile: 'build/.cachesalt, .yarnrc, remote/.yarnrc, **/yarn.lock, !**/node_modules/**/yarn.lock, !**/.*/**/yarn.lock, !samples/**/yarn.lock'
|
||||||
exec { mkdir -Force .build/node_modules_cache }
|
targetfolder: '**/node_modules, !**/node_modules/**/node_modules, !samples/**/node_modules'
|
||||||
exec { 7z.exe a .build/node_modules_cache/cache.7z -mx3 `@.build/node_modules_list.txt }
|
vstsFeed: 'BuildCache'
|
||||||
condition: and(succeeded(), ne(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), ne(variables['CacheRestored'], 'true'))
|
||||||
displayName: Create node_modules archive
|
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { yarn postinstall }
|
exec { yarn postinstall }
|
||||||
displayName: Run postinstall scripts
|
displayName: Run postinstall scripts
|
||||||
condition: and(succeeded(), eq(variables.NODE_MODULES_RESTORED, 'true'))
|
condition: and(succeeded(), eq(variables['CacheRestored'], 'true'))
|
||||||
|
|
||||||
- powershell: |
|
- powershell: |
|
||||||
. build/azure-pipelines/win32/exec.ps1
|
. build/azure-pipelines/win32/exec.ps1
|
||||||
@@ -102,6 +98,8 @@ steps:
|
|||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
exec { yarn gulp "package-rebuild-extensions" }
|
exec { yarn gulp "package-rebuild-extensions" }
|
||||||
exec { yarn gulp "vscode-win32-x64-min-ci" }
|
exec { yarn gulp "vscode-win32-x64-min-ci" }
|
||||||
|
exec { yarn gulp "vscode-reh-win32-x64-min" }
|
||||||
|
exec { yarn gulp "vscode-reh-web-win32-x64-min" }
|
||||||
exec { yarn gulp "vscode-win32-x64-code-helper" }
|
exec { yarn gulp "vscode-win32-x64-code-helper" }
|
||||||
exec { yarn gulp "vscode-win32-x64-inno-updater" }
|
exec { yarn gulp "vscode-win32-x64-inno-updater" }
|
||||||
displayName: Build
|
displayName: Build
|
||||||
@@ -119,19 +117,6 @@ steps:
|
|||||||
vstsPackageVersion: '*'
|
vstsPackageVersion: '*'
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_QUALITY'], 'saw'))
|
condition: and(succeeded(), eq(variables['VSCODE_QUALITY'], 'saw'))
|
||||||
|
|
||||||
- powershell: |
|
|
||||||
# Install TSGOps specific extensions
|
|
||||||
$ErrorActionPreference = "Stop"
|
|
||||||
$tempFilePath = (New-TemporaryFile).FullName
|
|
||||||
$zipFilePath = $tempFilePath + ".zip"
|
|
||||||
$extensionUri = "$(standalone-extensions-uri)"
|
|
||||||
$adsExtensionPath = "$(agent.builddirectory)\azuredatastudio-win32-x64\resources\app\extensions"
|
|
||||||
Invoke-WebRequest -Uri $extensionUri -OutFile $tempFilePath
|
|
||||||
Move-Item $tempFilePath $zipFilePath
|
|
||||||
Expand-Archive $zipFilePath -DestinationPath $adsExtensionPath
|
|
||||||
displayName: Install SAW Extensions
|
|
||||||
condition: and(succeeded(), eq(variables['VSCODE_QUALITY'], 'saw'))
|
|
||||||
|
|
||||||
# - powershell: | @anthonydresser unit tests timeout never existing the node process
|
# - powershell: | @anthonydresser unit tests timeout never existing the node process
|
||||||
# . build/azure-pipelines/win32/exec.ps1
|
# . build/azure-pipelines/win32/exec.ps1
|
||||||
# $ErrorActionPreference = "Stop"
|
# $ErrorActionPreference = "Stop"
|
||||||
|
|||||||
@@ -6,7 +6,8 @@
|
|||||||
const fs = require('fs');
|
const fs = require('fs');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
const os = require('os');
|
const os = require('os');
|
||||||
const { ipcRenderer } = require('electron');
|
const { remote } = require('electron');
|
||||||
|
const dialog = remote.dialog;
|
||||||
|
|
||||||
const builtInExtensionsPath = path.join(__dirname, '..', '..', 'product.json');
|
const builtInExtensionsPath = path.join(__dirname, '..', '..', 'product.json');
|
||||||
const controlFilePath = path.join(os.homedir(), '.vscode-oss-dev', 'extensions', 'control.json');
|
const controlFilePath = path.join(os.homedir(), '.vscode-oss-dev', 'extensions', 'control.json');
|
||||||
@@ -83,13 +84,17 @@ function render(el, state) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const localInput = renderOption(form, `local-${ext.name}`, 'Local', 'local', !!local);
|
const localInput = renderOption(form, `local-${ext.name}`, 'Local', 'local', !!local);
|
||||||
localInput.onchange = async function () {
|
localInput.onchange = function () {
|
||||||
const result = await ipcRenderer.invoke('pickdir');
|
const result = dialog.showOpenDialog(remote.getCurrentWindow(), {
|
||||||
|
title: 'Choose Folder',
|
||||||
|
properties: ['openDirectory']
|
||||||
|
});
|
||||||
|
|
||||||
if (result) {
|
if (result && result.length >= 1) {
|
||||||
control[ext.name] = result;
|
control[ext.name] = result[0];
|
||||||
setState({ builtin, control });
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
setState({ builtin, control });
|
||||||
};
|
};
|
||||||
|
|
||||||
if (local) {
|
if (local) {
|
||||||
|
|||||||
@@ -3,25 +3,12 @@
|
|||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||||
*--------------------------------------------------------------------------------------------*/
|
*--------------------------------------------------------------------------------------------*/
|
||||||
|
|
||||||
const { app, BrowserWindow, ipcMain, dialog } = require('electron');
|
const { app, BrowserWindow } = require('electron');
|
||||||
const url = require('url');
|
const url = require('url');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
|
|
||||||
let window = null;
|
let window = null;
|
||||||
|
|
||||||
ipcMain.handle('pickdir', async () => {
|
|
||||||
const result = await dialog.showOpenDialog(window, {
|
|
||||||
title: 'Choose Folder',
|
|
||||||
properties: ['openDirectory']
|
|
||||||
});
|
|
||||||
|
|
||||||
if (result.canceled || result.filePaths.length < 1) {
|
|
||||||
return undefined;
|
|
||||||
}
|
|
||||||
|
|
||||||
return result.filePaths[0];
|
|
||||||
});
|
|
||||||
|
|
||||||
app.once('ready', () => {
|
app.once('ready', () => {
|
||||||
window = new BrowserWindow({ width: 800, height: 600, webPreferences: { nodeIntegration: true, webviewTag: true, enableWebSQL: false, nativeWindowOpen: true } });
|
window = new BrowserWindow({ width: 800, height: 600, webPreferences: { nodeIntegration: true, webviewTag: true, enableWebSQL: false, nativeWindowOpen: true } });
|
||||||
window.setMenuBarVisibility(false);
|
window.setMenuBarVisibility(false);
|
||||||
|
|||||||
@@ -1,58 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
'use strict';
|
|
||||||
Object.defineProperty(exports, "__esModule", { value: true });
|
|
||||||
const vscode_universal_1 = require("vscode-universal");
|
|
||||||
const fs = require("fs-extra");
|
|
||||||
const path = require("path");
|
|
||||||
const plist = require("plist");
|
|
||||||
const product = require("../../product.json");
|
|
||||||
async function main() {
|
|
||||||
const buildDir = process.env['AGENT_BUILDDIRECTORY'];
|
|
||||||
const arch = process.env['VSCODE_ARCH'];
|
|
||||||
if (!buildDir) {
|
|
||||||
throw new Error('$AGENT_BUILDDIRECTORY not set');
|
|
||||||
}
|
|
||||||
const appName = product.nameLong + '.app';
|
|
||||||
const x64AppPath = path.join(buildDir, 'vscode-x64', appName);
|
|
||||||
const arm64AppPath = path.join(buildDir, 'vscode-arm64', appName);
|
|
||||||
const x64AsarPath = path.join(x64AppPath, 'Contents', 'Resources', 'app', 'node_modules.asar');
|
|
||||||
const arm64AsarPath = path.join(arm64AppPath, 'Contents', 'Resources', 'app', 'node_modules.asar');
|
|
||||||
const outAppPath = path.join(buildDir, `VSCode-darwin-${arch}`, appName);
|
|
||||||
const productJsonPath = path.resolve(outAppPath, 'Contents', 'Resources', 'app', 'product.json');
|
|
||||||
const infoPlistPath = path.resolve(outAppPath, 'Contents', 'Info.plist');
|
|
||||||
await vscode_universal_1.makeUniversalApp({
|
|
||||||
x64AppPath,
|
|
||||||
arm64AppPath,
|
|
||||||
x64AsarPath,
|
|
||||||
arm64AsarPath,
|
|
||||||
filesToSkip: [
|
|
||||||
'product.json',
|
|
||||||
'Credits.rtf',
|
|
||||||
'CodeResources',
|
|
||||||
'fsevents.node',
|
|
||||||
'.npmrc'
|
|
||||||
],
|
|
||||||
outAppPath,
|
|
||||||
force: true
|
|
||||||
});
|
|
||||||
let productJson = await fs.readJson(productJsonPath);
|
|
||||||
Object.assign(productJson, {
|
|
||||||
darwinUniversalAssetId: 'darwin-universal'
|
|
||||||
});
|
|
||||||
await fs.writeJson(productJsonPath, productJson);
|
|
||||||
let infoPlistString = await fs.readFile(infoPlistPath, 'utf8');
|
|
||||||
let infoPlistJson = plist.parse(infoPlistString);
|
|
||||||
Object.assign(infoPlistJson, {
|
|
||||||
LSRequiresNativeExecution: true
|
|
||||||
});
|
|
||||||
await fs.writeFile(infoPlistPath, plist.build(infoPlistJson), 'utf8');
|
|
||||||
}
|
|
||||||
if (require.main === module) {
|
|
||||||
main().catch(err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
@@ -1,66 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
'use strict';
|
|
||||||
|
|
||||||
import { makeUniversalApp } from 'vscode-universal';
|
|
||||||
import * as fs from 'fs-extra';
|
|
||||||
import * as path from 'path';
|
|
||||||
import * as plist from 'plist';
|
|
||||||
import * as product from '../../product.json';
|
|
||||||
|
|
||||||
async function main() {
|
|
||||||
const buildDir = process.env['AGENT_BUILDDIRECTORY'];
|
|
||||||
const arch = process.env['VSCODE_ARCH'];
|
|
||||||
|
|
||||||
if (!buildDir) {
|
|
||||||
throw new Error('$AGENT_BUILDDIRECTORY not set');
|
|
||||||
}
|
|
||||||
|
|
||||||
const appName = product.nameLong + '.app';
|
|
||||||
const x64AppPath = path.join(buildDir, 'vscode-x64', appName);
|
|
||||||
const arm64AppPath = path.join(buildDir, 'vscode-arm64', appName);
|
|
||||||
const x64AsarPath = path.join(x64AppPath, 'Contents', 'Resources', 'app', 'node_modules.asar');
|
|
||||||
const arm64AsarPath = path.join(arm64AppPath, 'Contents', 'Resources', 'app', 'node_modules.asar');
|
|
||||||
const outAppPath = path.join(buildDir, `VSCode-darwin-${arch}`, appName);
|
|
||||||
const productJsonPath = path.resolve(outAppPath, 'Contents', 'Resources', 'app', 'product.json');
|
|
||||||
const infoPlistPath = path.resolve(outAppPath, 'Contents', 'Info.plist');
|
|
||||||
|
|
||||||
await makeUniversalApp({
|
|
||||||
x64AppPath,
|
|
||||||
arm64AppPath,
|
|
||||||
x64AsarPath,
|
|
||||||
arm64AsarPath,
|
|
||||||
filesToSkip: [
|
|
||||||
'product.json',
|
|
||||||
'Credits.rtf',
|
|
||||||
'CodeResources',
|
|
||||||
'fsevents.node',
|
|
||||||
'.npmrc'
|
|
||||||
],
|
|
||||||
outAppPath,
|
|
||||||
force: true
|
|
||||||
});
|
|
||||||
|
|
||||||
let productJson = await fs.readJson(productJsonPath);
|
|
||||||
Object.assign(productJson, {
|
|
||||||
darwinUniversalAssetId: 'darwin-universal'
|
|
||||||
});
|
|
||||||
await fs.writeJson(productJsonPath, productJson);
|
|
||||||
|
|
||||||
let infoPlistString = await fs.readFile(infoPlistPath, 'utf8');
|
|
||||||
let infoPlistJson = plist.parse(infoPlistString);
|
|
||||||
Object.assign(infoPlistJson, {
|
|
||||||
LSRequiresNativeExecution: true
|
|
||||||
});
|
|
||||||
await fs.writeFile(infoPlistPath, plist.build(infoPlistJson), 'utf8');
|
|
||||||
}
|
|
||||||
|
|
||||||
if (require.main === module) {
|
|
||||||
main().catch(err => {
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
@@ -24,6 +24,7 @@ async function main() {
|
|||||||
const appFrameworkPath = path.join(appRoot, appName, 'Contents', 'Frameworks');
|
const appFrameworkPath = path.join(appRoot, appName, 'Contents', 'Frameworks');
|
||||||
const helperAppBaseName = product.nameShort;
|
const helperAppBaseName = product.nameShort;
|
||||||
const gpuHelperAppName = helperAppBaseName + ' Helper (GPU).app';
|
const gpuHelperAppName = helperAppBaseName + ' Helper (GPU).app';
|
||||||
|
const pluginHelperAppName = helperAppBaseName + ' Helper (Plugin).app';
|
||||||
const rendererHelperAppName = helperAppBaseName + ' Helper (Renderer).app';
|
const rendererHelperAppName = helperAppBaseName + ' Helper (Renderer).app';
|
||||||
const defaultOpts = {
|
const defaultOpts = {
|
||||||
app: path.join(appRoot, appName),
|
app: path.join(appRoot, appName),
|
||||||
@@ -42,11 +43,14 @@ async function main() {
|
|||||||
// TODO(deepak1556): Incorrectly declared type in electron-osx-sign
|
// TODO(deepak1556): Incorrectly declared type in electron-osx-sign
|
||||||
ignore: (filePath) => {
|
ignore: (filePath) => {
|
||||||
return filePath.includes(gpuHelperAppName) ||
|
return filePath.includes(gpuHelperAppName) ||
|
||||||
|
filePath.includes(pluginHelperAppName) ||
|
||||||
filePath.includes(rendererHelperAppName);
|
filePath.includes(rendererHelperAppName);
|
||||||
} });
|
} });
|
||||||
const gpuHelperOpts = Object.assign(Object.assign({}, defaultOpts), { app: path.join(appFrameworkPath, gpuHelperAppName), entitlements: path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-gpu-entitlements.plist'), 'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-gpu-entitlements.plist') });
|
const gpuHelperOpts = Object.assign(Object.assign({}, defaultOpts), { app: path.join(appFrameworkPath, gpuHelperAppName), entitlements: path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-gpu-entitlements.plist'), 'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-gpu-entitlements.plist') });
|
||||||
|
const pluginHelperOpts = Object.assign(Object.assign({}, defaultOpts), { app: path.join(appFrameworkPath, pluginHelperAppName), entitlements: path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-plugin-entitlements.plist'), 'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-plugin-entitlements.plist') });
|
||||||
const rendererHelperOpts = Object.assign(Object.assign({}, defaultOpts), { app: path.join(appFrameworkPath, rendererHelperAppName), entitlements: path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-renderer-entitlements.plist'), 'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-renderer-entitlements.plist') });
|
const rendererHelperOpts = Object.assign(Object.assign({}, defaultOpts), { app: path.join(appFrameworkPath, rendererHelperAppName), entitlements: path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-renderer-entitlements.plist'), 'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-renderer-entitlements.plist') });
|
||||||
await codesign.signAsync(gpuHelperOpts);
|
await codesign.signAsync(gpuHelperOpts);
|
||||||
|
await codesign.signAsync(pluginHelperOpts);
|
||||||
await codesign.signAsync(rendererHelperOpts);
|
await codesign.signAsync(rendererHelperOpts);
|
||||||
await codesign.signAsync(appOpts);
|
await codesign.signAsync(appOpts);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -29,6 +29,7 @@ async function main(): Promise<void> {
|
|||||||
const appFrameworkPath = path.join(appRoot, appName, 'Contents', 'Frameworks');
|
const appFrameworkPath = path.join(appRoot, appName, 'Contents', 'Frameworks');
|
||||||
const helperAppBaseName = product.nameShort;
|
const helperAppBaseName = product.nameShort;
|
||||||
const gpuHelperAppName = helperAppBaseName + ' Helper (GPU).app';
|
const gpuHelperAppName = helperAppBaseName + ' Helper (GPU).app';
|
||||||
|
const pluginHelperAppName = helperAppBaseName + ' Helper (Plugin).app';
|
||||||
const rendererHelperAppName = helperAppBaseName + ' Helper (Renderer).app';
|
const rendererHelperAppName = helperAppBaseName + ' Helper (Renderer).app';
|
||||||
|
|
||||||
const defaultOpts: codesign.SignOptions = {
|
const defaultOpts: codesign.SignOptions = {
|
||||||
@@ -50,6 +51,7 @@ async function main(): Promise<void> {
|
|||||||
// TODO(deepak1556): Incorrectly declared type in electron-osx-sign
|
// TODO(deepak1556): Incorrectly declared type in electron-osx-sign
|
||||||
ignore: (filePath: string) => {
|
ignore: (filePath: string) => {
|
||||||
return filePath.includes(gpuHelperAppName) ||
|
return filePath.includes(gpuHelperAppName) ||
|
||||||
|
filePath.includes(pluginHelperAppName) ||
|
||||||
filePath.includes(rendererHelperAppName);
|
filePath.includes(rendererHelperAppName);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
@@ -61,6 +63,13 @@ async function main(): Promise<void> {
|
|||||||
'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-gpu-entitlements.plist'),
|
'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-gpu-entitlements.plist'),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const pluginHelperOpts: codesign.SignOptions = {
|
||||||
|
...defaultOpts,
|
||||||
|
app: path.join(appFrameworkPath, pluginHelperAppName),
|
||||||
|
entitlements: path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-plugin-entitlements.plist'),
|
||||||
|
'entitlements-inherit': path.join(baseDir, 'azure-pipelines', 'darwin', 'helper-plugin-entitlements.plist'),
|
||||||
|
};
|
||||||
|
|
||||||
const rendererHelperOpts: codesign.SignOptions = {
|
const rendererHelperOpts: codesign.SignOptions = {
|
||||||
...defaultOpts,
|
...defaultOpts,
|
||||||
app: path.join(appFrameworkPath, rendererHelperAppName),
|
app: path.join(appFrameworkPath, rendererHelperAppName),
|
||||||
@@ -69,6 +78,7 @@ async function main(): Promise<void> {
|
|||||||
};
|
};
|
||||||
|
|
||||||
await codesign.signAsync(gpuHelperOpts);
|
await codesign.signAsync(gpuHelperOpts);
|
||||||
|
await codesign.signAsync(pluginHelperOpts);
|
||||||
await codesign.signAsync(rendererHelperOpts);
|
await codesign.signAsync(rendererHelperOpts);
|
||||||
await codesign.signAsync(appOpts as any);
|
await codesign.signAsync(appOpts as any);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,27 +5,12 @@
|
|||||||
|
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
import * as path from 'path';
|
const path = require('path');
|
||||||
import * as cp from 'child_process';
|
|
||||||
import * as _ from 'underscore';
|
|
||||||
const parseSemver = require('parse-semver');
|
const parseSemver = require('parse-semver');
|
||||||
|
const cp = require('child_process');
|
||||||
|
const _ = require('underscore');
|
||||||
|
|
||||||
interface Tree {
|
function asYarnDependency(prefix, tree) {
|
||||||
readonly name: string;
|
|
||||||
readonly children?: Tree[];
|
|
||||||
}
|
|
||||||
|
|
||||||
interface FlatDependency {
|
|
||||||
readonly name: string;
|
|
||||||
readonly version: string;
|
|
||||||
readonly path: string;
|
|
||||||
}
|
|
||||||
|
|
||||||
interface Dependency extends FlatDependency {
|
|
||||||
readonly children: Dependency[];
|
|
||||||
}
|
|
||||||
|
|
||||||
function asYarnDependency(prefix: string, tree: Tree): Dependency | null {
|
|
||||||
let parseResult;
|
let parseResult;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@@ -57,7 +42,7 @@ function asYarnDependency(prefix: string, tree: Tree): Dependency | null {
|
|||||||
return { name, version, path: dependencyPath, children };
|
return { name, version, path: dependencyPath, children };
|
||||||
}
|
}
|
||||||
|
|
||||||
function getYarnProductionDependencies(cwd: string): Dependency[] {
|
function getYarnProductionDependencies(cwd) {
|
||||||
const raw = cp.execSync('yarn list --json', { cwd, encoding: 'utf8', env: { ...process.env, NODE_ENV: 'production' }, stdio: [null, null, 'inherit'] });
|
const raw = cp.execSync('yarn list --json', { cwd, encoding: 'utf8', env: { ...process.env, NODE_ENV: 'production' }, stdio: [null, null, 'inherit'] });
|
||||||
const match = /^{"type":"tree".*$/m.exec(raw);
|
const match = /^{"type":"tree".*$/m.exec(raw);
|
||||||
|
|
||||||
@@ -65,22 +50,25 @@ function getYarnProductionDependencies(cwd: string): Dependency[] {
|
|||||||
throw new Error('Could not parse result of `yarn list --json`');
|
throw new Error('Could not parse result of `yarn list --json`');
|
||||||
}
|
}
|
||||||
|
|
||||||
const trees = JSON.parse(match[0]).data.trees as Tree[];
|
const trees = JSON.parse(match[0]).data.trees;
|
||||||
|
|
||||||
return trees
|
return trees
|
||||||
.map(tree => asYarnDependency(path.join(cwd, 'node_modules'), tree))
|
.map(tree => asYarnDependency(path.join(cwd, 'node_modules'), tree))
|
||||||
.filter<Dependency>((dep): dep is Dependency => !!dep);
|
.filter(dep => !!dep);
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getProductionDependencies(cwd: string): FlatDependency[] {
|
function getProductionDependencies(cwd) {
|
||||||
const result: FlatDependency[] = [];
|
const result = [];
|
||||||
const deps = getYarnProductionDependencies(cwd);
|
const deps = getYarnProductionDependencies(cwd);
|
||||||
const flatten = (dep: Dependency) => { result.push({ name: dep.name, version: dep.version, path: dep.path }); dep.children.forEach(flatten); };
|
const flatten = dep => { result.push({ name: dep.name, version: dep.version, path: dep.path }); dep.children.forEach(flatten); };
|
||||||
deps.forEach(flatten);
|
deps.forEach(flatten);
|
||||||
|
|
||||||
return _.uniq(result);
|
return _.uniq(result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
module.exports.getProductionDependencies = getProductionDependencies;
|
||||||
|
|
||||||
if (require.main === module) {
|
if (require.main === module) {
|
||||||
const root = path.dirname(path.dirname(__dirname));
|
const root = path.dirname(__dirname);
|
||||||
console.log(JSON.stringify(getProductionDependencies(root), null, ' '));
|
console.log(JSON.stringify(getProductionDependencies(root), null, ' '));
|
||||||
}
|
}
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
const es = require('event-stream');
|
|
||||||
const vfs = require('vinyl-fs');
|
|
||||||
const { jsHygieneFilter, tsHygieneFilter } = require('./filters');
|
|
||||||
|
|
||||||
function eslint() {
|
|
||||||
const gulpeslint = require('gulp-eslint');
|
|
||||||
return vfs
|
|
||||||
.src([...jsHygieneFilter, ...tsHygieneFilter], { base: '.', follow: true, allowEmpty: true })
|
|
||||||
.pipe(
|
|
||||||
gulpeslint({
|
|
||||||
configFile: '.eslintrc.json',
|
|
||||||
rulePaths: ['./build/lib/eslint'],
|
|
||||||
})
|
|
||||||
)
|
|
||||||
.pipe(gulpeslint.formatEach('compact'))
|
|
||||||
.pipe(
|
|
||||||
gulpeslint.results((results) => {
|
|
||||||
if (results.warningCount > 0 || results.errorCount > 0) {
|
|
||||||
throw new Error('eslint failed with warnings and/or errors');
|
|
||||||
}
|
|
||||||
})
|
|
||||||
).pipe(es.through(function () { /* noop, important for the stream to end */ }));
|
|
||||||
}
|
|
||||||
|
|
||||||
if (require.main === module) {
|
|
||||||
eslint().on('error', (err) => {
|
|
||||||
console.error();
|
|
||||||
console.error(err);
|
|
||||||
process.exit(1);
|
|
||||||
});
|
|
||||||
}
|
|
||||||
152
build/filters.js
152
build/filters.js
@@ -1,152 +0,0 @@
|
|||||||
/*---------------------------------------------------------------------------------------------
|
|
||||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
||||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
|
||||||
*--------------------------------------------------------------------------------------------*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Hygiene works by creating cascading subsets of all our files and
|
|
||||||
* passing them through a sequence of checks. Here are the current subsets,
|
|
||||||
* named according to the checks performed on them. Each subset contains
|
|
||||||
* the following one, as described in mathematical notation:
|
|
||||||
*
|
|
||||||
* all ⊃ eol ⊇ indentation ⊃ copyright ⊃ typescript
|
|
||||||
*/
|
|
||||||
|
|
||||||
module.exports.all = [
|
|
||||||
'*',
|
|
||||||
'build/**/*',
|
|
||||||
'extensions/**/*',
|
|
||||||
'scripts/**/*',
|
|
||||||
'src/**/*',
|
|
||||||
'test/**/*',
|
|
||||||
'!out*/**',
|
|
||||||
'!test/**/out/**',
|
|
||||||
'!**/node_modules/**',
|
|
||||||
];
|
|
||||||
|
|
||||||
module.exports.indentationFilter = [
|
|
||||||
'**',
|
|
||||||
|
|
||||||
// except specific files
|
|
||||||
'!**/ThirdPartyNotices.txt',
|
|
||||||
'!**/LICENSE.{txt,rtf}',
|
|
||||||
'!LICENSES.chromium.html',
|
|
||||||
'!**/LICENSE',
|
|
||||||
'!src/vs/nls.js',
|
|
||||||
'!src/vs/nls.build.js',
|
|
||||||
'!src/vs/css.js',
|
|
||||||
'!src/vs/css.build.js',
|
|
||||||
'!src/vs/loader.js',
|
|
||||||
'!src/vs/base/common/insane/insane.js',
|
|
||||||
'!src/vs/base/common/marked/marked.js',
|
|
||||||
'!src/vs/base/common/semver/semver.js',
|
|
||||||
'!src/vs/base/node/terminateProcess.sh',
|
|
||||||
'!src/vs/base/node/cpuUsage.sh',
|
|
||||||
'!test/unit/assert.js',
|
|
||||||
'!resources/linux/snap/electron-launch',
|
|
||||||
'!build/ext.js',
|
|
||||||
|
|
||||||
// except specific folders
|
|
||||||
'!test/automation/out/**',
|
|
||||||
'!test/monaco/out/**',
|
|
||||||
'!test/smoke/out/**',
|
|
||||||
'!extensions/typescript-language-features/test-workspace/**',
|
|
||||||
'!extensions/vscode-api-tests/testWorkspace/**',
|
|
||||||
'!extensions/vscode-api-tests/testWorkspace2/**',
|
|
||||||
'!build/monaco/**',
|
|
||||||
'!build/win32/**',
|
|
||||||
|
|
||||||
// except multiple specific files
|
|
||||||
'!**/package.json',
|
|
||||||
'!**/yarn.lock',
|
|
||||||
'!**/yarn-error.log',
|
|
||||||
|
|
||||||
// except multiple specific folders
|
|
||||||
'!**/codicon/**',
|
|
||||||
'!**/fixtures/**',
|
|
||||||
'!**/lib/**',
|
|
||||||
'!extensions/**/dist/**',
|
|
||||||
'!extensions/**/out/**',
|
|
||||||
'!extensions/**/snippets/**',
|
|
||||||
'!extensions/**/syntaxes/**',
|
|
||||||
'!extensions/**/themes/**',
|
|
||||||
'!extensions/**/colorize-fixtures/**',
|
|
||||||
|
|
||||||
// except specific file types
|
|
||||||
'!src/vs/*/**/*.d.ts',
|
|
||||||
'!src/typings/**/*.d.ts',
|
|
||||||
'!extensions/**/*.d.ts',
|
|
||||||
'!**/*.{svg,exe,png,bmp,jpg,scpt,bat,cmd,cur,ttf,woff,eot,md,ps1,template,yaml,yml,d.ts.recipe,ico,icns,plist}',
|
|
||||||
'!build/{lib,download,darwin}/**/*.js',
|
|
||||||
'!build/**/*.sh',
|
|
||||||
'!build/azure-pipelines/**/*.js',
|
|
||||||
'!build/azure-pipelines/**/*.config',
|
|
||||||
'!**/Dockerfile',
|
|
||||||
'!**/Dockerfile.*',
|
|
||||||
'!**/*.Dockerfile',
|
|
||||||
'!**/*.dockerfile',
|
|
||||||
'!extensions/markdown-language-features/media/*.js',
|
|
||||||
'!extensions/simple-browser/media/*.js',
|
|
||||||
];
|
|
||||||
|
|
||||||
module.exports.copyrightFilter = [
|
|
||||||
'**',
|
|
||||||
'!**/*.desktop',
|
|
||||||
'!**/*.json',
|
|
||||||
'!**/*.html',
|
|
||||||
'!**/*.template',
|
|
||||||
'!**/*.md',
|
|
||||||
'!**/*.bat',
|
|
||||||
'!**/*.cmd',
|
|
||||||
'!**/*.ico',
|
|
||||||
'!**/*.icns',
|
|
||||||
'!**/*.xml',
|
|
||||||
'!**/*.sh',
|
|
||||||
'!**/*.txt',
|
|
||||||
'!**/*.xpm',
|
|
||||||
'!**/*.opts',
|
|
||||||
'!**/*.disabled',
|
|
||||||
'!**/*.code-workspace',
|
|
||||||
'!**/*.js.map',
|
|
||||||
'!build/**/*.init',
|
|
||||||
'!resources/linux/snap/snapcraft.yaml',
|
|
||||||
'!resources/win32/bin/code.js',
|
|
||||||
'!resources/web/code-web.js',
|
|
||||||
'!resources/completions/**',
|
|
||||||
'!extensions/configuration-editing/build/inline-allOf.ts',
|
|
||||||
'!extensions/markdown-language-features/media/highlight.css',
|
|
||||||
'!extensions/html-language-features/server/src/modes/typescript/*',
|
|
||||||
'!extensions/*/server/bin/*',
|
|
||||||
'!src/vs/editor/test/node/classification/typescript-test.ts',
|
|
||||||
];
|
|
||||||
|
|
||||||
module.exports.jsHygieneFilter = [
|
|
||||||
'src/**/*.js',
|
|
||||||
'build/gulpfile.*.js',
|
|
||||||
'!src/vs/loader.js',
|
|
||||||
'!src/vs/css.js',
|
|
||||||
'!src/vs/nls.js',
|
|
||||||
'!src/vs/css.build.js',
|
|
||||||
'!src/vs/nls.build.js',
|
|
||||||
'!src/**/insane.js',
|
|
||||||
'!src/**/marked.js',
|
|
||||||
'!src/**/semver.js',
|
|
||||||
'!**/test/**',
|
|
||||||
];
|
|
||||||
|
|
||||||
module.exports.tsHygieneFilter = [
|
|
||||||
'src/**/*.ts',
|
|
||||||
'test/**/*.ts',
|
|
||||||
'extensions/**/*.ts',
|
|
||||||
'!src/vs/*/**/*.d.ts',
|
|
||||||
'!src/typings/**/*.d.ts',
|
|
||||||
'!extensions/**/*.d.ts',
|
|
||||||
'!**/fixtures/**',
|
|
||||||
'!**/typings/**',
|
|
||||||
'!**/node_modules/**',
|
|
||||||
'!extensions/**/colorize-fixtures/**',
|
|
||||||
'!extensions/vscode-api-tests/testWorkspace/**',
|
|
||||||
'!extensions/vscode-api-tests/testWorkspace2/**',
|
|
||||||
'!extensions/**/*.test.ts',
|
|
||||||
'!extensions/html-language-features/server/lib/jquery.d.ts',
|
|
||||||
];
|
|
||||||
@@ -11,11 +11,6 @@ const task = require('./lib/task');
|
|||||||
const compilation = require('./lib/compilation');
|
const compilation = require('./lib/compilation');
|
||||||
|
|
||||||
// Full compile, including nls and inline sources in sourcemaps, for build
|
// Full compile, including nls and inline sources in sourcemaps, for build
|
||||||
const compileBuildTask = task.define('compile-build',
|
const compileBuildTask = task.define('compile-build', task.series(util.rimraf('out-build'), compilation.compileTask('src', 'out-build', true)));
|
||||||
task.series(
|
|
||||||
util.rimraf('out-build'),
|
|
||||||
compilation.compileTask('src', 'out-build', true)
|
|
||||||
)
|
|
||||||
);
|
|
||||||
gulp.task(compileBuildTask);
|
gulp.task(compileBuildTask);
|
||||||
exports.compileBuildTask = compileBuildTask;
|
exports.compileBuildTask = compileBuildTask;
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user