-
Notifications
You must be signed in to change notification settings - Fork 4
/
package.json
204 lines (204 loc) · 8.34 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
{
"name": "php-phan",
"displayName": "PHP Phan (Analyzer)",
"description": "Phan - static analyzer for PHP, minimizing false positives.",
"publisher": "TysonAndre",
"author": "Tyson Andre <[email protected]>",
"license": "MIT",
"private": true,
"preview": false,
"version": "5.1.0",
"engines": {
"node": ">=14",
"vscode": "^1.43.0",
"os": [
"darwin",
"linux"
]
},
"keywords": [
"php",
"phan",
"static-analysis",
"error-detection"
],
"categories": [
"Languages",
"Linters"
],
"icon": "images/logo.png",
"galleryBanner": {
"color": "#6682BA",
"theme": "dark"
},
"repository": {
"type": "git",
"url": "https://github.com/phan/phan.git"
},
"bugs": {
"url": "https://github.com/phan/phan/issues"
},
"activationEvents": [
"onLanguage:php",
"workspaceContains:**/*.php"
],
"main": "./out/extension",
"scripts": {
"build": "tsc -p .",
"watch": "tsc -w -p .",
"lint": "eslint 'src/**/*.ts'"
},
"devDependencies": {
"@types/mocha": "^9.1.1",
"@types/mz": "^2.7.4",
"@types/node": "^12.20.55",
"@types/semver": "^7.3.13",
"@types/vscode": "^1.43.0",
"@typescript-eslint/eslint-plugin": "^5.42.0",
"@typescript-eslint/parser": "^5.42.0",
"eslint": "^8.26.0",
"typescript": "^4.8.4",
"vsce": "^2.13.0",
"vscode-test": "^1.6.1"
},
"dependencies": {
"mz": "^2.7.0",
"semver": "^7.3.8",
"vscode-languageclient": "^6.1.4"
},
"contributes": {
"configuration": {
"type": "object",
"title": "PHP - Phan Analyzer",
"properties": {
"phan.phpExecutablePath": {
"type": [
"string",
"null"
],
"default": null,
"scope": "machine",
"markdownDescription": "Optional, defaults to searching for \"php\". The path to a PHP 7.2+ executable to use to execute the Phan server. The PHP 7.2+ installation should preferably include and enable the PHP modules `pcntl`, as well as the third party `ast` (php-ast) module from https://pecl.php.net/ast\nFor the best analysis results, install and enable the same PECL extensions that are used by the project being analyzed. (Modifying requires restart)"
},
"phan.analyzedProjectDirectory": {
"type": [
"string",
"array",
"null"
],
"items": {
"type": "string"
},
"default": null,
"scope": "machine",
"markdownDescription": "Required. The absolute path to a project folder which Phan will analyze (or an array of 1 or more folders to independently analyze). `.phan/config.php` must contain the Phan config for this project. (See an example config at https://github.com/phan/phan#usage) (In the future, this VS Code extension may support analyzing more than one project) (Modifying requires restart)"
},
"phan.enableDebugLog": {
"type": "boolean",
"default": false,
"markdownDescription": "Enable this to print messages to the debug console when developing or debugging this VS Code extension. (Modifying requires restart)"
},
"phan.enableGoToDefinition": {
"type": "boolean",
"default": true,
"markdownDescription": "If enabled, Phan supports \"Go To Definition\" requests. This may conflict with \"PHP IntelliSense\"."
},
"phan.enableHover": {
"type": "boolean",
"default": true,
"markdownDescription": "If enabled, Phan supports \"Hover\" requests. This may conflict with \"PHP IntelliSense\"."
},
"phan.enableCompletion": {
"type": "boolean",
"default": true,
"markdownDescription": "If enabled, Phan supports \"Completion\" requests. This may conflict with \"PHP IntelliSense\". (Disabled by default)."
},
"phan.analyzedFileExtensions": {
"type": "array",
"default": [
"php"
],
"markdownDescription": "A list of file extensions to request Phan to analyze. By default, this only includes `'php'`. This may need to be synchronized with `.phan/config.php`'s `'analyzed_file_extensions'` (Modifying requires restart)"
},
"phan.useFallbackParser": {
"type": "boolean",
"default": true,
"markdownDescription": "When enabled, this makes a best effort attempt at analyzing the remaining valid statements of PHP files with syntax errors (Phan will continue emitting syntax errors). This is also enabled by `phan.enableCompletion` (Modifying requires restart)"
},
"phan.analyzeOnlyOnSave": {
"type": "boolean",
"default": false,
"markdownDescription": "Enable this to run Phan analysis only on file save (Not while editing the file). This greatly reduces CPU usage, but you don't learn about potential issues as promptly."
},
"phan.quick": {
"type": "boolean",
"default": false,
"markdownDescription": "Enable this to speed up phan analysis by not recursing into function calls. Slightly faster. (Modifying requires restart)"
},
"phan.unusedVariableDetection": {
"type": "boolean",
"default": false,
"markdownDescription": "Enables unused variable and parameter detection (analyzes the implementations of functions, methods, and closures)."
},
"phan.redundantConditionDetection": {
"type": "boolean",
"default": false,
"markdownDescription": "Enables redundant and impossible condition detection."
},
"phan.memoryLimit": {
"type": [
"string",
"null"
],
"default": null,
"markdownDescription": "The memory limit of Phan (the php language server) in bytes. Format: Number[K|M|G] (e.g. `\"1G\"` or `\"200M\"`). Set to `null` for no memory limit (default). (Modifying requires restart)",
"pattern": "^\\d+[KMG]?$"
},
"phan.connectToServerWithStdio": {
"type": [
"boolean",
"null"
],
"default": false,
"scope": "machine",
"markdownDescription": "If this is set to true, this VSCode extension will use stdio instead of the default of TCP to communicate with the Phan server. Enabling this may help if you have issues getting Phan to analyze your project. (Modifying requires restart)"
},
"phan.additionalCLIFlags": {
"type": "array",
"default": [],
"scope": "machine",
"markdownDescription": "Optional (Advanced). Setting this will provide these additional CLI flags to the Phan server. See https://github.com/phan/phan#usage (e.g. `[\"--quick\"]`) (Modifying requires restart)"
},
"phan.phanScriptPath": {
"type": [
"string",
"null"
],
"default": null,
"scope": "machine",
"markdownDescription": "Optional (Advanced). If provided, this overrides the Phan script to use, e.g. `/path/to/phan_git_checkout/phan`. (Modifying requires restart)"
},
"phan.allowPolyfillParser": {
"type": "boolean",
"default": true,
"markdownDescription": "If set to true, this extension will run even if php-ast is not installed. Installing php-ast is strongly recommended for performance reasons and for consistency with full Phan analysis."
},
"phan.allowMissingPcntl": {
"type": "boolean",
"default": true,
"markdownDescription": "If set to true, this extension will use a substitute for `pcntl` if `pcntl` is not installed (New and experimental). This must be set to true on Windows."
},
"phan.forceMissingPcntl": {
"type": "boolean",
"default": false,
"markdownDescription": "Useful for debugging. Forces Phan to manually save and restore the analyzed project's state instead of using `pcntl`"
},
"phan.useRelativePatterns": {
"type": "boolean",
"default": false,
"markdownDescription": "Limit events sent to the language server to those within `phan.analyzedProjectDirectory` where possible. Useful when multiple directories are analyzed (e.g. fixes issues with hover flickering)."
}
}
}
}
}