-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpackage.json
More file actions
304 lines (304 loc) · 9.3 KB
/
package.json
File metadata and controls
304 lines (304 loc) · 9.3 KB
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
{
"name": "tsqlformatter",
"displayName": "T-SQL Formatter",
"description": "Rich SQL Server T-SQL formatter with profiles, import/export, and extensive options",
"version": "0.1.0",
"engines": {
"vscode": "^1.90.0"
},
"categories": [
"Other"
],
"activationEvents": [
"onLanguage:sql"
],
"main": "./dist/extension.js",
"contributes": {
"commands": [
{
"command": "tsqlformatter.saveProfile",
"title": "T-SQL Formatter: Save Active Profile"
},
{
"command": "tsqlformatter.loadProfile",
"title": "T-SQL Formatter: Load Profile for Workspace"
},
{
"command": "tsqlformatter.exportProfile",
"title": "T-SQL Formatter: Export Active Profile"
},
{
"command": "tsqlformatter.importProfile",
"title": "T-SQL Formatter: Import Profile"
}
],
"configuration": {
"title": "T-SQL Formatter",
"properties": {
"tsqlformatter.ignoreTabSettings": {
"type": "boolean",
"default": false,
"description": "Ignore VS Code tabSize and insertSpaces settings."
},
"tsqlformatter.tabSizeOverride": {
"type": "number",
"default": 4,
"minimum": 0,
"description": "Override tabSize when ignoreTabSettings is enabled."
},
"tsqlformatter.insertSpacesOverride": {
"type": "boolean",
"default": true,
"description": "Override insertSpaces when ignoreTabSettings is enabled."
},
"tsqlformatter.profile": {
"type": "string",
"default": "default",
"description": "Active profile name to use for formatting."
},
"tsqlformatter.keywordCasing": {
"type": "string",
"enum": [
"upper",
"lower",
"original"
],
"default": "upper",
"description": "Keyword casing preference."
},
"tsqlformatter.identifierCasing": {
"type": "string",
"enum": [
"upper",
"lower",
"original"
],
"default": "original",
"description": "Identifier casing preference (tables, columns)."
},
"tsqlformatter.indentSize": {
"type": "number",
"default": 4,
"minimum": 0,
"description": "Spaces per indentation level."
},
"tsqlformatter.indentStyle": {
"type": "string",
"enum": [
"standard",
"central"
],
"default": "standard",
"description": "Standard keyword positioning vs maintaining a central alignment column."
},
"tsqlformatter.indentStyleMode": {
"type": "string",
"enum": [
"ignore",
"enable"
],
"default": "ignore",
"description": "Whether to apply central alignment."
},
"tsqlformatter.indentCentralClauses": {
"type": "array",
"items": {
"type": "string",
"enum": [
"SELECT",
"WHERE",
"ON",
"SET"
]
},
"default": [
"ON",
"SET"
],
"description": "Clauses that should participate in central alignment when enabled."
},
"tsqlformatter.indentAlignColumn": {
"type": "number",
"default": 40,
"minimum": 0,
"description": "Target column for central alignment when enabled."
},
"tsqlformatter.columnsCommaPlacement": {
"type": "string",
"enum": [
"leading",
"trailing",
"ignore"
],
"default": "trailing",
"description": "Placement of commas in column lists (SELECT/ORDER BY/GROUP BY); 'ignore' preserves existing formatting."
},
"tsqlformatter.alignColumnDefinitions": {
"type": "boolean",
"default": true,
"description": "Align column definitions in CREATE TABLE statements."
},
"tsqlformatter.newlineAfterSelect": {
"type": "boolean",
"default": true,
"description": "Place each SELECT list item on a new line."
},
"tsqlformatter.newlineAfterFrom": {
"type": "boolean",
"default": true,
"description": "Place FROM and JOIN clauses on new lines."
},
"tsqlformatter.logicalOperatorNewline": {
"type": "string",
"enum": [
"before",
"after",
"none"
],
"default": "after",
"description": "Break before or after logical operators AND/OR."
},
"tsqlformatter.tabulateAlias": {
"type": "boolean",
"default": false,
"description": "Right-align aliases to the longest line in the SELECT clause."
},
"tsqlformatter.aliasKeyword": {
"type": "string",
"enum": [
"enable",
"remove",
"ignore"
],
"default": "ignore",
"description": "Add (enable), remove, or ignore the ' AS' keyword across aliased items (columns, tables, etc.)."
},
"tsqlformatter.joinAlignment": {
"type": "string",
"enum": [
"left",
"indent"
],
"default": "indent",
"description": "Alignment style for JOIN clauses."
},
"tsqlformatter.expressionWidth": {
"type": "number",
"default": 0,
"minimum": 0,
"description": "Max characters per line before breaking expressions (0 disables)."
},
"tsqlformatter.safeWrapDelimiters": {
"type": "array",
"items": {
"type": "string",
"enum": [
"comma",
"AND",
"OR"
]
},
"default": [
"comma",
"AND",
"OR"
],
"description": "Delimiters allowed for wrapping when enforcing expressionWidth."
},
"tsqlformatter.linesBetweenQueries": {
"type": "number",
"default": 1,
"minimum": 0,
"description": "Number of blank lines between statements."
},
"tsqlformatter.parenthesisSpacing": {
"type": "string",
"enum": [
"none",
"inside",
"outside"
],
"default": "none",
"description": "Spaces around parentheses."
},
"tsqlformatter.operatorSpacing": {
"type": "boolean",
"default": true,
"description": "Insert spaces around operators (=, +, -, *, /)."
},
"tsqlformatter.denseOperators": {
"type": "boolean",
"default": false,
"description": "Strip whitespace around operators such as + or >=. Overrides operatorSpacing when true."
},
"tsqlformatter.cteStyle": {
"type": "string",
"enum": [
"newline",
"inline"
],
"default": "newline",
"description": "Format CTEs with WITH on its own line vs inline."
},
"tsqlformatter.windowFunctionStyle": {
"type": "string",
"enum": [
"compact",
"multiline"
],
"default": "compact",
"description": "Format OVER(PARTITION BY...) compact or multi-line."
},
"tsqlformatter.newlineBeforeSemicolon": {
"type": "boolean",
"default": false,
"description": "Place semicolon on its own line before statement end."
},
"tsqlformatter.bracketIdentifiers": {
"type": "string",
"enum": [
"add",
"remove",
"ignore"
],
"default": "ignore",
"description": "Add or remove square brackets around identifiers (tables, columns, schemas, aliases)."
}
}
}
},
"scripts": {
"vscode:prepublish": "npm run package",
"compile": "npm run check-types && npm run lint && node esbuild.js",
"watch": "npm-run-all -p watch:*",
"watch:esbuild": "node esbuild.js --watch",
"watch:tsc": "tsc --noEmit --watch --project tsconfig.json",
"package": "npm run check-types && npm run lint && node esbuild.js --production",
"compile-tests": "tsc -p . --outDir out",
"watch-tests": "tsc -p . -w --outDir out",
"pretest": "npm run compile-tests && npm run compile && npm run lint",
"check-types": "tsc --noEmit",
"lint": "eslint src",
"test": "set VSCODE_USER_DATA_DIR=.vscode-test-data && vscode-test",
"test:unit": "vitest --run",
"test:watch": "vitest",
"coverage": "vitest --run --coverage",
"build": "npm run compile",
"audit": "npm audit"
},
"devDependencies": {
"@types/mocha": "^10.0.10",
"@types/node": "20.x",
"@types/vscode": "^1.90.0",
"@vitest/coverage-v8": "^4.0.15",
"@vscode/test-cli": "^0.0.12",
"@vscode/test-electron": "^2.5.2",
"esbuild": "^0.27.0",
"eslint": "^9.39.1",
"npm-run-all": "^4.1.5",
"typescript": "^5.9.3",
"typescript-eslint": "^8.46.3",
"vitest": "^4.0.15"
},
"extensionDependencies": []
}