change setting field to php
parent
14a9171a4d
commit
14e6a9f19a
|
@ -57,9 +57,8 @@
|
||||||
},
|
},
|
||||||
"contributes": {
|
"contributes": {
|
||||||
"configuration": {
|
"configuration": {
|
||||||
"title": "PHP-Intellisense",
|
|
||||||
"properties": {
|
"properties": {
|
||||||
"phpintellisense.memoryLimit": {
|
"php.memoryLimit": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"default": "-1",
|
"default": "-1",
|
||||||
"description": "The memory limit of the php language server. [Number][K|M|G]. Use '-1' to allow unlimited use of the RAM(default)."
|
"description": "The memory limit of the php language server. [Number][K|M|G]. Use '-1' to allow unlimited use of the RAM(default)."
|
||||||
|
|
|
@ -12,9 +12,7 @@ export async function activate(context: vscode.ExtensionContext): Promise<void>
|
||||||
const conf = vscode.workspace.getConfiguration('php');
|
const conf = vscode.workspace.getConfiguration('php');
|
||||||
const executablePath = conf.get<string>('executablePath') || 'php';
|
const executablePath = conf.get<string>('executablePath') || 'php';
|
||||||
|
|
||||||
const specificSettings = vscode.workspace.getConfiguration('phpintellisense');
|
const memoryLimit = conf.get<string>('memoryLimit') || '-1';
|
||||||
|
|
||||||
const memoryLimit = specificSettings.get<string>('memoryLimit') || '-1';
|
|
||||||
|
|
||||||
if (memoryLimit !== '-1' && !memoryLimit.match('~^(\d+)(K|M|G|)$~')) {
|
if (memoryLimit !== '-1' && !memoryLimit.match('~^(\d+)(K|M|G|)$~')) {
|
||||||
const selected = await vscode.window.showErrorMessage(
|
const selected = await vscode.window.showErrorMessage(
|
||||||
|
|
Loading…
Reference in New Issue