blob: 04ff8f53c9e58612bf27d75c2de93b07f0764e93 [file] [log] [blame]
import * as vscode from 'vscode';
/**
* Gets the config value `mlir.<key>`, with an optional workspace folder.
*/
export function get<T>(key: string,
workspaceFolder: vscode.WorkspaceFolder = null,
defaultValue: T = undefined): T {
return vscode.workspace.getConfiguration('mlir', workspaceFolder)
.get<T>(key, defaultValue);
}
/**
* Sets the config value `mlir.<key>`.
*/
export function update<T>(key: string, value: T,
target?: vscode.ConfigurationTarget) {
return vscode.workspace.getConfiguration('mlir').update(key, value, target);
}