forked from UniqueVision/plpgsql-lsp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
package.json
309 lines (309 loc) · 9.91 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
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
{
"name": "vscode-plpgsql-lsp",
"displayName": "PostgreSQL Language Server",
"description": "VSCode PostgreSQL and PL/pgSQL Language Server.",
"license": "MIT",
"version": "2.11.1",
"icon": "images/postgres.png",
"repository": {
"type": "git",
"url": "https://github.com/UniqueVision/plpgsql-lsp"
},
"publisher": "uniquevision",
"categories": [],
"keywords": [
"postgres",
"Postgres",
"PostgreSQL",
"PL",
"plpgsql",
"PL/pgSQL",
"Language Server"
],
"engines": {
"vscode": "^1.68.0"
},
"activationEvents": [
"onLanguage:postgres",
"onCommand:plpgsql-lsp.executeFileQuery",
"onCommand:plpgsql-lsp.validateWorkspace"
],
"main": "./client/out/extension",
"scripts": {
"vscode:prepublish": "npm run build",
"build": "npm run clean && webpack --mode production --config ./client/webpack.config.js && webpack --mode production --config ./server/webpack.config.js",
"build:dev": "npm run clean && webpack --mode none --config ./client/webpack.config.js && webpack --mode none --config ./server/webpack.config.js",
"tsc": "tsc --noEmit --project ./tsconfig.json && npm run tsc:client && npm run tsc:server",
"tsc:client": "tsc --noEmit --project ./client/tsconfig.json",
"tsc:server": "tsc --noEmit --project ./server/tsconfig.json",
"compile": "tsc -b",
"compile:client": "tsc -b ./client/tsconfig.json",
"compile:server": "tsc -b ./server/tsconfig.json",
"watch": "webpack --watch",
"package:linux": "vsce package --target linux-x64",
"package:mac": "vsce package --target darwin-x64",
"package:windows": "vsce package --target win32-x64",
"lint": "eslint ./client/src ./server/src --ext .ts,.tsx --fix",
"postinstall": "cd client && npm install && cd ../server && npm install && cd ..",
"test": "cd server && npm run test && cd ..",
"test:ci": "cd server && npm run test:ci && cd ..",
"clean": "rimraf client/out && rimraf server/out"
},
"contributes": {
"commands": [
{
"command": "plpgsql-lsp.executeFileQuery",
"title": "PL/pgSQL: Execute the Current File Query"
},
{
"command": "plpgsql-lsp.validateWorkspace",
"title": "PL/pgSQL: Validate the Workspace Files"
}
],
"menus": {
"commandPalette": [
{
"command": "plpgsql-lsp.executeFileQuery",
"when": "editorLangId == postgres"
},
{
"command": "plpgsql-lsp.validateWorkspace",
"when": "editorLangId == postgres"
}
]
},
"languages": [
{
"id": "postgres",
"extensions": [
".pgsql",
".psql"
],
"aliases": [
"Postgres"
],
"configuration": "./language-configuration.json"
}
],
"grammars": [
{
"language": "postgres",
"scopeName": "source.pgsql",
"path": "./syntaxes/pgsql.tmLanguage"
}
],
"configuration": {
"type": "object",
"title": "PostgreSQL connection configuration",
"properties": {
"plpgsqlLanguageServer.host": {
"scope": "resource",
"type": "string",
"default": "localhost",
"description": "Your database host."
},
"plpgsqlLanguageServer.port": {
"scope": "resource",
"type": "number",
"default": 5432,
"description": "Your database port."
},
"plpgsqlLanguageServer.database": {
"scope": "resource",
"type": "string",
"nullable": true,
"description": "Your database name."
},
"plpgsqlLanguageServer.user": {
"scope": "resource",
"type": "string",
"nullable": true,
"description": "Your database user."
},
"plpgsqlLanguageServer.password": {
"scope": "resource",
"type": "string",
"nullable": true,
"description": "Your database password."
},
"plpgsqlLanguageServer.definitionFiles": {
"scope": "resource",
"type": "array",
"default": [
"**/*.psql",
"**/*.pgsql"
],
"description": "The pattern list of the definition files.",
"items": {
"type": "string"
}
},
"plpgsqlLanguageServer.defaultSchema": {
"scope": "resource",
"type": "string",
"default": "public",
"description": "Default schema name."
},
"plpgsqlLanguageServer.validateOn": {
"scope": "resource",
"type": "string",
"enum": [
"save",
"change"
],
"default": "change",
"description": "Specify when to validate files. Default: 'change'"
},
"plpgsqlLanguageServer.queryParameterPattern": {
"scope": "resource",
"type": "string",
"default": "\\$[1-9][0-9]*",
"description": "Query parameter pattern. the pattern is described by regular expression."
},
"plpgsqlLanguageServer.keywordQueryParameterPattern": {
"scope": "resource",
"type": "array",
"default": [],
"description": "Keyword query parameter patterns. Patterns must include \"{keyword}\", as in \"@{keyword}\".",
"items": {
"type": "string"
}
},
"plpgsqlLanguageServer.statements": {
"properties": {
"separatorPattern": {
"scope": "resource",
"type": "string",
"required": true,
"example": "-- name:[\\s]+.*",
"description": "Prepared statement separator regex pattern."
},
"diagnosticsLevels": {
"scope": "resource",
"type": "object",
"default": null,
"description": "Override diagnostic levels for statements.",
"properties": {
"disableFlag": {
"scope": "resource",
"type": "string",
"default": "disable",
"enum": [
"disable",
"warning"
],
"description": "Set diagnostic level for the disabled validation flag."
}
}
}
},
"default": null,
"scope": "resource",
"type": "object",
"description": "If set, multiple statements in a file can be analyzed based on a separator."
},
"plpgsqlLanguageServer.migrations": {
"properties": {
"upFiles": {
"scope": "resource",
"type": "array",
"items": {
"type": "string"
},
"description": "Up migrations file glob pattern. Executed by sorted filename order.",
"required": true,
"example": [
"*.up.pgsql"
]
},
"downFiles": {
"scope": "resource",
"type": "array",
"items": {
"type": "string"
},
"description": "Down migrations file glob pattern. Executed by sorted filename order.",
"required": true,
"example": [
"*.down.pgsql"
]
},
"postMigrationFiles": {
"scope": "resource",
"type": "array",
"items": {
"type": "string"
},
"description": "Post-migration file glob pattern. Executed by sorted filename order.",
"required": true,
"default": [],
"example": [
"*.post.pgsql"
]
},
"target": {
"scope": "resource",
"type": "string",
"enum": [
"all",
"up/down"
],
"default": "up/down",
"description": "Specify target files to be migrated in the background. Default: 'up/down'"
}
},
"scope": "resource",
"default": null,
"type": "object",
"description": "If set, migrations will be applied for all analyses. If the current file is a migration file, execution will run until the previous migration."
},
"plpgsqlLanguageServer.enableExecuteFileQueryCommand": {
"scope": "resource",
"type": "boolean",
"default": true,
"description": "Enable/Disable \"Execute the Current File Query\" command."
},
"plpgsqlLanguageServer.workspaceValidationTargetFiles": {
"scope": "resource",
"type": "array",
"default": [],
"description": "The pattern list of the workspace validation target files.",
"items": {
"type": "string"
}
}
},
"required": [
"plpgsqlLanguageServer.host",
"plpgsqlLanguageServer.port",
"plpgsqlLanguageServer.defaultSchema"
]
}
},
"devDependencies": {
"@types/node": "^18.0.0",
"@typescript-eslint/eslint-plugin": "^5.30.0",
"@typescript-eslint/parser": "^5.30.0",
"eslint": "^8.18.0",
"eslint-config-prettier": "^8.5.0",
"eslint-config-standard": "^17.0.0",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-prettier": "^4.2.1",
"eslint-plugin-promise": "^6.0.0",
"eslint-plugin-simple-import-sort": "^7.0.0",
"jest": "^28.1.2",
"merge-options": "^3.0.4",
"node-loader": "^2.0.0",
"rimraf": "^3.0.2",
"ts-jest": "^28.0.5",
"ts-loader": "^9.3.1",
"ts-node": "^10.8.1",
"tsconfig-paths-webpack-plugin": "^3.5.2",
"typescript": "^4.7.4",
"vsce": "^2.9.2",
"webpack": "^5.73.0",
"webpack-cli": "^4.10.0",
"webpack-node-externals": "^3.0.0"
}
}