Boilerplate for SQL Bindings Extension (#18624)

* boilerplate for sql bindings extension

* edit gulpfile task as it was trying to find specific menus within package.json
This commit is contained in:
Vasu Bhog
2022-03-04 15:16:45 -08:00
committed by GitHub
parent 8e9957adbe
commit c9aa3e9f4b
19 changed files with 206 additions and 6 deletions

View File

@@ -129,16 +129,19 @@ gulp.task('package-external-extensions', task.series(
const packageManifestPath = path.join(packageDir, 'package.json');
const json = require('gulp-json-editor');
const packageJsonStream = gulp.src(packageManifestPath) // Create stream for the original package.json
.pipe(json(data => { // And now use gulp-json-editor to modify the contents
.pipe(json(data => {
// And now use gulp-json-editor to modify the contents
const updateData = JSON.parse(fs.readFileSync(vscodeManifestFullPath)); // Read in the set of values to replace from package.vscode.json
Object.keys(updateData).forEach(key => {
data[key] = updateData[key];
});
// Remove ADS-only menus. This is a subset of the menus listed in https://github.com/microsoft/azuredatastudio/blob/main/src/vs/workbench/api/common/menusExtensionPoint.ts
// More can be added to the list as needed.
['objectExplorer/item/context', 'dataExplorer/context', 'dashboard/toolbar'].forEach(menu => {
delete data.contributes.menus[menu];
});
if(data.contributes?.menus){
// Remove ADS-only menus. This is a subset of the menus listed in https://github.com/microsoft/azuredatastudio/blob/main/src/vs/workbench/api/common/menusExtensionPoint.ts
// More can be added to the list as needed.
['objectExplorer/item/context', 'dataExplorer/context', 'dashboard/toolbar'].forEach(menu => {
delete data.contributes.menus[menu];
});
}
return data;
}, { beautify: false }))
.pipe(gulp.dest(packageDir));

View File

@@ -135,6 +135,7 @@ const extensionsFilter = filter([
'**/schema-compare.xlf',
'**/server-report.xlf',
'**/sql-assessment.xlf',
'**/sql-bindings.xlf',
'**/sql-database-projects.xlf',
'**/sql-migration.xlf',
'**/xml-language-features.xlf'

View File

@@ -231,6 +231,7 @@ const externalExtensions = [
'schema-compare',
'server-report',
'sql-assessment',
'sql-bindings',
'sql-database-projects',
'sql-migration'
];

View File

@@ -267,6 +267,7 @@ const externalExtensions = [
'schema-compare',
'server-report',
'sql-assessment',
'sql-bindings',
'sql-database-projects',
'sql-migration'
];

View File

@@ -48,6 +48,7 @@ exports.dirs = [
'extensions/server-report',
'extensions/simple-browser',
'extensions/sql-assessment',
'extensions/sql-bindings',
'extensions/sql-database-projects',
'extensions/sql-migration',
'extensions/vscode-test-resolver',