Fix sql projects net6 warnings (#17673)

* fix .net 6 error showing on startup

* fix double warning

* addressing comments

* update key string
This commit is contained in:
Kim Santiago
2021-11-16 10:02:15 -10:00
committed by GitHub
parent 1b83c4623d
commit 66c438db4d
5 changed files with 5 additions and 7 deletions

View File

@@ -43,7 +43,7 @@
{
"title": "%sqlDatabaseProjects.Settings%",
"properties": {
"sqlDatabaseProjects.netCoreSDKLocation": {
"sqlDatabaseProjects.netCoreSDK Location": {
"type": "string",
"description": "%sqlDatabaseProjects.netCoreInstallLocation%"
},

View File

@@ -35,7 +35,7 @@
"sqlDatabaseProjects.Settings": "Database Projects",
"sqlDatabaseProjects.netCoreInstallLocation": "Full path to .NET Core SDK on the machine.",
"sqlDatabaseProjects.netCoreDoNotAsk": "Whether to prompt the user to install .NET Core when not detected.",
"sqlDatabaseProjects.netCoreDowngradeDoNotShow": "Whether to prompt the user to set .NET SDK version when a newer unsupported version is detected.",
"sqlDatabaseProjects.netCoreDowngradeDoNotShow": "Whether to prompt the user to install .NET SDK version and add global.json to project when a newer unsupported version is detected.",
"sqlDatabaseProjects.nodejsDoNotAsk": "Whether to prompt the user to install Node.js when not detected.",
"sqlDatabaseProjects.autorestSqlVersion": "Which version of Autorest.Sql to use from NPM. Latest will be used if not set.",
"sqlDatabaseProjects.welcome": "No database projects currently open.\n[New Project](command:sqlDatabaseProjects.new)\n[Open Project](command:sqlDatabaseProjects.open)\n[Create Project From Database](command:sqlDatabaseProjects.importDatabase)",

View File

@@ -82,9 +82,6 @@ export default class MainController implements vscode.Disposable {
IconPathHelper.setExtensionContext(this.extensionContext);
await templates.loadTemplates(path.join(this.context.extensionPath, 'resources', 'templates'));
// ensure .net core is installed
await this.netcoreTool.findOrInstallNetCore();
}
public dispose(): void {

View File

@@ -252,7 +252,8 @@ export class ProjectsController {
const message = utils.getErrorMessage(err);
if (err instanceof DotNetError) {
void vscode.window.showErrorMessage(message);
// DotNetErrors already get shown by the netCoreTool so just show this one in the console
console.error(message);
} else {
void vscode.window.showErrorMessage(constants.projBuildFailed(message));
}

View File

@@ -17,7 +17,7 @@ import { ShellCommandOptions, ShellExecutionHelper } from './shellExecutionHelpe
const localize = nls.loadMessageBundle();
export const DBProjectConfigurationKey: string = 'sqlDatabaseProjects';
export const NetCoreInstallLocationKey: string = 'netCoreSDKLocation';
export const NetCoreInstallLocationKey: string = 'netCoreSDK Location';
export const NetCoreDoNotAskAgainKey: string = 'netCoreDoNotAsk';
export const NetCoreDowngradeDoNotShowAgainKey: string = 'netCoreDowngradeDoNotShow';
export const NetCoreNonWindowsDefaultPath = '/usr/local/share';