Include companion VS Code extension VSIX as part of build/release (#4254)
This commit is contained in:
parent
34c1b5811a
commit
e4ed1aabac
|
@ -38,3 +38,4 @@ packages/*/coverage/
|
||||||
# Generated files
|
# Generated files
|
||||||
packages/cli/src/generated/
|
packages/cli/src/generated/
|
||||||
.integration-tests/
|
.integration-tests/
|
||||||
|
packages/vscode-ide-companion/*.vsix
|
||||||
|
|
Binary file not shown.
|
@ -29,7 +29,9 @@
|
||||||
"watch:tsc": "tsc --noEmit --watch --project tsconfig.json",
|
"watch:tsc": "tsc --noEmit --watch --project tsconfig.json",
|
||||||
"package": "vsce package --no-dependencies",
|
"package": "vsce package --no-dependencies",
|
||||||
"check-types": "tsc --noEmit",
|
"check-types": "tsc --noEmit",
|
||||||
"lint": "eslint src"
|
"lint": "eslint src",
|
||||||
|
"test": "echo \"vscode-ide-companion has no tests yet\"",
|
||||||
|
"test:ci": "echo \"vscode-ide-companion has no tests yet\""
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/cors": "^2.8.19",
|
"@types/cors": "^2.8.19",
|
||||||
|
|
|
@ -33,6 +33,10 @@ if (!existsSync(join(root, 'node_modules'))) {
|
||||||
// build all workspaces/packages
|
// build all workspaces/packages
|
||||||
execSync('npm run generate', { stdio: 'inherit', cwd: root });
|
execSync('npm run generate', { stdio: 'inherit', cwd: root });
|
||||||
execSync('npm run build --workspaces', { stdio: 'inherit', cwd: root });
|
execSync('npm run build --workspaces', { stdio: 'inherit', cwd: root });
|
||||||
|
execSync('npx --yes @vscode/vsce package --no-dependencies', {
|
||||||
|
stdio: 'inherit',
|
||||||
|
cwd: join(root, 'packages', 'vscode-ide-companion'),
|
||||||
|
});
|
||||||
|
|
||||||
// also build container image if sandboxing is enabled
|
// also build container image if sandboxing is enabled
|
||||||
// skip (-s) npm install + build since we did that above
|
// skip (-s) npm install + build since we did that above
|
||||||
|
|
|
@ -45,3 +45,11 @@ for (const workspace of rootPackageJson.workspaces) {
|
||||||
rmSync(join(pkgDir, 'dist'), RMRF_OPTIONS);
|
rmSync(join(pkgDir, 'dist'), RMRF_OPTIONS);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Clean up vsix files in vscode-ide-companion
|
||||||
|
const vsixFiles = globSync('packages/vscode-ide-companion/*.vsix', {
|
||||||
|
cwd: root,
|
||||||
|
});
|
||||||
|
for (const vsixFile of vsixFiles) {
|
||||||
|
rmSync(join(root, vsixFile), RMRF_OPTIONS);
|
||||||
|
}
|
||||||
|
|
|
@ -37,4 +37,12 @@ for (const file of sbFiles) {
|
||||||
copyFileSync(join(root, file), join(bundleDir, basename(file)));
|
copyFileSync(join(root, file), join(bundleDir, basename(file)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Find and copy all .vsix files from packages to the root of the bundle directory
|
||||||
|
const vsixFiles = glob.sync('packages/vscode-ide-companion/*.vsix', {
|
||||||
|
cwd: root,
|
||||||
|
});
|
||||||
|
for (const file of vsixFiles) {
|
||||||
|
copyFileSync(join(root, file), join(bundleDir, basename(file)));
|
||||||
|
}
|
||||||
|
|
||||||
console.log('Assets copied to bundle/');
|
console.log('Assets copied to bundle/');
|
||||||
|
|
Loading…
Reference in New Issue