mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-15 17:22:25 -05:00
Add sql bindings package reference to project (#16912)
* list packages and add packages working * cleanup and remove list packages * cleanup * change to pull in latest package version
This commit is contained in:
@@ -2,8 +2,9 @@ import * as vscode from 'vscode';
|
||||
import { BindingType } from 'vscode-mssql';
|
||||
import * as constants from '../common/constants';
|
||||
import * as utils from '../common/utils';
|
||||
import { PackageHelper } from '../tools/packageHelper';
|
||||
|
||||
export async function launchAddSqlBindingQuickpick(uri: vscode.Uri | undefined): Promise<void> {
|
||||
export async function launchAddSqlBindingQuickpick(uri: vscode.Uri | undefined, packageHelper: PackageHelper): Promise<void> {
|
||||
if (!uri) {
|
||||
// this command only shows in the command palette when the active editor is a .cs file, so we can safely assume that's the scenario
|
||||
// when this is called without a uri
|
||||
@@ -95,5 +96,8 @@ export async function launchAddSqlBindingQuickpick(uri: vscode.Uri | undefined):
|
||||
vscode.window.showErrorMessage(e);
|
||||
return;
|
||||
}
|
||||
|
||||
// 6. Add sql extension package reference to project. If the reference is already there, it doesn't get added again
|
||||
await packageHelper.addPackageToAFProjectContainingFile(uri.fsPath, constants.sqlExtensionPackageName);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user