-
Notifications
You must be signed in to change notification settings - Fork 1
/
package.json
259 lines (259 loc) · 10.2 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
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
{
"name": "sfdx-code-analyzer-vscode",
"displayName": "Salesforce Code Analyzer",
"description": "Salesforce Code Analyzer is a unified tool for source code analysis. Run Code Analyzer to scan multiple languages in your code and add diagnostic info to your code that describes the violations.",
"bugs": {
"url": "https://github.com/forcedotcom/sfdx-code-analyzer-vscode/issues"
},
"repository": {
"url": "https://github.com/forcedotcom/sfdx-code-analyzer-vscode"
},
"icon": "images/CodeAnalyzer-small.png",
"galleryBanner": {
"color": "#ECECEC",
"theme": "light"
},
"version": "1.3.0",
"publisher": "salesforce",
"license": "BSD-3-Clause",
"engines": {
"vscode": "^1.82.0"
},
"categories": [
"Programming Languages",
"Linters",
"Testing"
],
"keywords": [
"Salesforce Code Analyzer",
"Salesforce Graph Engine",
"Code Analyzer",
"Graph Engine",
"SFGE",
"SFCA"
],
"dependencies": {
"cross-spawn": "^7.0.3",
"glob": "^8.0.3",
"globby": "^11.0.0",
"semver": "^7.5.4"
},
"devDependencies": {
"@istanbuljs/nyc-config-typescript": "^1.0.2",
"@types/chai": "^4.3.5",
"@types/cross-spawn": "^6.0.2",
"@types/glob": "^8.0.0",
"@types/mocha": "^10.0.1",
"@types/node": "16.x",
"@types/sinon": "^10.0.15",
"@types/vscode": "^1.74.0",
"@typescript-eslint/eslint-plugin": "^5.45.0",
"@typescript-eslint/parser": "^5.45.0",
"@vscode/test-electron": "^2.2.0",
"@vscode/vsce": "^2.20.0",
"chai": "^4.3.7",
"esbuild": "^0.23.0",
"eslint": "^8.28.0",
"mocha": "^10.1.0",
"nyc": "^15.1.0",
"ovsx": "^0.8.3",
"proxyquire": "^2.1.3",
"sinon": "^15.1.0",
"ts-node": "^10.9.1",
"typescript": "^4.9.3"
},
"extensionDependencies": [
"salesforce.salesforcedx-vscode-core"
],
"scripts": {
"vscode:prepublish": "yarn run compile && node esbuild.js --production",
"build": "node esbuild.js",
"compile": "tsc -p ./",
"watch": "tsc -watch -p ./",
"pretest": "yarn run compile && yarn run lint",
"lint": "eslint src --ext ts",
"test": "node ./out/test/runTest.js"
},
"activationEvents": [
"workspaceContains:sfdx-project.json"
],
"main": "./out/extension.js",
"contributes": {
"commands": [
{
"command": "sfca.runOnActiveFile",
"title": "SFDX: Scan Current File with Code Analyzer"
},
{
"command": "sfca.runOnSelected",
"title": "SFDX: Scan Selected Files or Folders with Code Analyzer"
},
{
"command": "sfca.runDfaOnSelectedMethod",
"title": "SFDX: Scan Selected Method with Graph Engine Path-Based Analysis"
},
{
"command": "sfca.removeDiagnosticsOnActiveFile",
"title": "SFDX: Clear Code Analyzer Violations from Current File"
},
{
"command": "sfca.removeDiagnosticsOnSelectedFile",
"title": "SFDX: Clear Code Analyzer Violations from Selected Files or Folders"
},
{
"command": "sfca.runDfa",
"title": "SFDX: Scan Project with Graph Engine Path-Based Analysis"
},
{
"command": "sfca.runApexGuruAnalysisOnSelectedFile",
"title": "SFDX: Scan Selected File for Performance Issues with ApexGuru"
},
{
"command": "sfca.runApexGuruAnalysisOnCurrentFile",
"title": "SFDX: Scan Current File for Performance Issues with ApexGuru"
}
],
"configuration": {
"title": "Salesforce Code Analyzer",
"properties": {
"codeAnalyzer.pMD.customConfigFile": {
"type": "string",
"default": "",
"description": "Replace Code Analyzer's default PMD config file, choose a custom file."
},
"codeAnalyzer.graphEngine.disableWarningViolations": {
"type": "boolean",
"default": false,
"description": "Suppress warning violations, such as those related to StripInaccessible READ access."
},
"codeAnalyzer.graphEngine.threadTimeout": {
"type": "number",
"default": 900000,
"description": "After the thread timeout elapses, the path evaluation aborts. The default timeout is 900,000 milliseconds."
},
"codeAnalyzer.graphEngine.pathExpansionLimit": {
"type": "number",
"default": 0,
"description": "An upper boundary to limit the complexity of code analyzed by Graph Engine. The default of 0 is a dynamically determined limit that's based on heap space. To learn more about heap space, see OutOfMemory errors in the Graph Engine documentation."
},
"codeAnalyzer.graphEngine.jvmArgs": {
"type": "string",
"description": "The Java Virtual Machine (JVM) arguments used to optimize Salesforce Graph Engine execution for your system."
},
"codeAnalyzer.analyzeOnSave.enabled": {
"type": "boolean",
"default": false,
"description": "Scan files on save automatically."
},
"codeAnalyzer.analyzeOnOpen.enabled": {
"type": "boolean",
"default": false,
"description": "Scan files on open automatically."
},
"codeAnalyzer.scanner.engines": {
"type": "string",
"default": "pmd,retire-js,eslint-lwc",
"description": "The engines to run. Specify multiple values as a comma-separated list. Possible values are pmd, pmd-appexchange, retire-js, eslint, eslint-lwc, and eslint-typescript."
},
"codeAnalyzer.normalizeSeverity.enabled": {
"type": "boolean",
"default": false,
"description": "Output normalized severity (high, moderate, low) and engine-specific severity across all engines."
},
"codeAnalyzer.rules.category": {
"type": "string",
"description": "The categories of rules to run. Specify multiple values as a comma-separated list. Run 'sf scanner rule list -e' in the terminal for the list of categories associated with a specific engine."
},
"codeAnalyzer.apexGuru.enabled": {
"type": "boolean",
"default": false,
"description": "Discover critical problems and performance issues in your Apex code with ApexGuru, which analyzes your Apex files for you. This feature is in a closed pilot; contact your account representative to learn more."
},
"codeAnalyzer.partialGraphEngineScans.enabled": {
"type": "boolean",
"default": false,
"description": "Enables partial Salesforce Graph Engine scans on only the code you've modified since the initial full scan. (Beta)"
}
}
},
"menus": {
"commandPalette": [
{
"command": "sfca.runOnActiveFile",
"when": "true"
},
{
"command": "sfca.runOnSelected",
"when": "false"
},
{
"command": "sfca.runDfaOnSelectedMethod",
"when": "false"
},
{
"command": "sfca.runDfa",
"when": "sfca.partialRunsEnabled"
},
{
"command": "sfca.removeDiagnosticsOnActiveFile",
"when": "true"
},
{
"command": "sfca.removeDiagnosticsOnSelectedFile",
"when": "false"
},
{
"command": "sfca.runApexGuruAnalysisOnSelectedFile",
"when": "false"
},
{
"command": "sfca.runApexGuruAnalysisOnCurrentFile",
"when": "sfca.apexGuruEnabled && resourceExtname =~ /\\.cls|\\.trigger|\\.apex/"
}
],
"editor/context": [
{
"command": "sfca.runOnActiveFile"
},
{
"command": "sfca.runDfaOnSelectedMethod"
},
{
"command": "sfca.removeDiagnosticsOnActiveFile"
},
{
"command": "sfca.runApexGuruAnalysisOnCurrentFile",
"when": "sfca.apexGuruEnabled && resourceExtname =~ /\\.cls|\\.trigger|\\.apex/"
}
],
"explorer/context": [
{
"command": "sfca.runOnSelected"
},
{
"command": "sfca.removeDiagnosticsOnSelectedFile",
"when": "true"
},
{
"command": "sfca.runApexGuruAnalysisOnSelectedFile",
"when": "sfca.apexGuruEnabled && resourceExtname =~ /\\.cls|\\.trigger|\\.apex/"
}
]
},
"languages": [
{
"id": "apex",
"aliases": [
"Apex",
"apex"
],
"extensions": [
".cls",
".trigger",
".soql",
".apex"
]
}
]
}
}