Bundle SsmsMin directly into extension (#5450)

This commit is contained in:
Charles Gagnon
2019-05-09 18:28:49 -07:00
committed by GitHub
parent a501214bfa
commit 2b8e0cc6c4
7 changed files with 17 additions and 394 deletions

View File

@@ -4,8 +4,6 @@
*--------------------------------------------------------------------------------------------*/
'use strict';
import * as vscode from 'vscode';
export interface IPackageInfo {
name: string;
version: string;
@@ -22,25 +20,6 @@ export function getPackageInfo(packageJson: any): IPackageInfo {
}
}
/**
* Get the configuration for a extensionName
* @param extensionName The string name of the extension to get the configuration for
* @param resource The optional URI, as a URI object or a string, to use to get resource-scoped configurations
*/
export function getConfiguration(extensionName?: string, resource?: vscode.Uri | string): vscode.WorkspaceConfiguration {
if (typeof resource === 'string') {
try {
resource = this.parseUri(resource);
} catch (e) {
resource = undefined;
}
} else if (!resource) {
// Fix to avoid adding lots of errors to debug console. Expects a valid resource or null, not undefined
resource = null;
}
return vscode.workspace.getConfiguration(extensionName, resource as vscode.Uri);
}
/**
* Escapes all single-quotes (') by prefixing them with another single quote ('')
* ' => ''