-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathpackage.json
426 lines (426 loc) · 11.7 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
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
{
"name": "qx-drafts",
"displayName": "草稿本(Drafts Scratch)",
"description": "一个草稿本,方便管理代码草稿和临时文件,再也不用多打开一个窗口了",
"publisher": "qcqx",
"keywords": [
"draft",
"草稿",
"草稿本",
"scratch",
"note"
],
"repository": {
"type": "git",
"url": "https://github.com/qxchuckle/vsc-drafts.git"
},
"version": "0.2.9",
"engines": {
"vscode": "^1.70.0"
},
"categories": [
"Other"
],
"activationEvents": [
"onStartupFinished",
"onView:qx-drafts"
],
"main": "./out/extension.js",
"icon": "resource/images/logo.png",
"contributes": {
"viewsContainers": {
"activitybar": [
{
"id": "qx-drafts-container",
"title": "草稿本 (Drafts Scratch)",
"icon": "resource/images/drafts1.svg"
}
]
},
"views": {
"qx-drafts-container": [
{
"id": "qx-drafts",
"name": "本地草稿详情"
},
{
"id": "qx-drafts-github",
"name": "GitHub 远端草稿本"
},
{
"id": "qx-drafts-list",
"name": "草稿本列表"
}
]
},
"viewsWelcome": [
{
"view": "qx-drafts",
"contents": "还没有选择草稿本 [learn more](https://github.com/qxchuckle/vsc-drafts)。\n[选择草稿本文件夹](command:qx-drafts.showFileTree)"
},
{
"view": "qx-drafts-list",
"contents": "还没有保存的草稿本 [learn more](https://github.com/qxchuckle/vsc-drafts)。\n[添加当前草稿本](command:qx-drafts-list.addDrafts)"
},
{
"view": "qx-drafts-github",
"contents": "还没有关联的 GitHub 仓库 [learn more](https://github.com/qxchuckle/vsc-drafts)。\n[初始化并选择 GitHub 仓库](command:qx-drafts-github.init)"
}
],
"menus": {
"view/title": [
{
"command": "qx-drafts.showFileTree",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.refresh",
"group": "navigation",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.createFile",
"group": "navigation",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.createFolder",
"group": "navigation",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.openInExplorer",
"group": "navigation",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.openInTerminal",
"group": "navigation",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.openInNewWindow",
"group": "navigation",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts-list.addDrafts",
"when": "view == qx-drafts-list"
},
{
"command": "qx-drafts-list.addGithub",
"when": "view == qx-drafts-list"
},
{
"command": "qx-drafts-github.refresh",
"group": "navigation",
"when": "view == qx-drafts-github"
},
{
"command": "qx-drafts-github.createFile",
"group": "navigation",
"when": "view == qx-drafts-github"
},
{
"command": "qx-drafts-github.init",
"when": "view == qx-drafts-github"
},
{
"command": "qx-drafts-github.openInGithub",
"group": "navigation",
"when": "view == qx-drafts-github"
},
{
"command": "qx-drafts-github.clearCache",
"when": "view == qx-drafts-github"
},
{
"command": "qx-drafts-github.clearAllCache",
"when": "view == qx-drafts-github"
},
{
"command": "qx-drafts-github.exit",
"when": "view == qx-drafts-github"
}
],
"view/item/context": [
{
"command": "qx-drafts.delete",
"when": "view == qx-drafts && viewItem != rootItem"
},
{
"command": "qx-drafts.rename",
"when": "view == qx-drafts && viewItem != rootItem"
},
{
"command": "qx-drafts.createFile",
"when": "view == qx-drafts && (viewItem == folder || viewItem == rootItem)"
},
{
"command": "qx-drafts.createFolder",
"when": "view == qx-drafts && (viewItem == folder || viewItem == rootItem)"
},
{
"command": "qx-drafts.createFile",
"group": "inline",
"when": "view == qx-drafts && (viewItem == folder || viewItem == rootItem)"
},
{
"command": "qx-drafts.createFolder",
"group": "inline",
"when": "view == qx-drafts && (viewItem == folder || viewItem == rootItem)"
},
{
"command": "qx-drafts.openInExplorer",
"group": "inline",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.openInTerminal",
"group": "inline",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.openInNewWindow",
"when": "view == qx-drafts"
},
{
"command": "qx-drafts.openInNewWindow",
"group": "inline",
"when": "view == qx-drafts && viewItem == rootItem"
},
{
"command": "qx-drafts-list.deleteDrafts",
"when": "view == qx-drafts-list && viewItem != rootItem",
"group": "inline"
},
{
"command": "qx-drafts-list.renameDrafts",
"when": "view == qx-drafts-list && viewItem != rootItem",
"group": "inline"
},
{
"command": "qx-drafts-github.createFile",
"when": "view == qx-drafts-github && (viewItem == folder || viewItem == rootItem)",
"group": "inline"
},
{
"command": "qx-drafts-github.deleteFile",
"when": "view == qx-drafts-github && viewItem != rootItem",
"group": "inline"
},
{
"command": "qx-drafts-github.openInGithub",
"when": "view == qx-drafts-github && viewItem == rootItem",
"group": "inline"
}
]
},
"commands": [
{
"command": "qx-drafts.showFileTree",
"title": "草稿本:选择文件夹"
},
{
"command": "qx-drafts.openFile",
"title": "打开文件"
},
{
"command": "qx-drafts.refresh",
"title": "刷新",
"icon": {
"light": "resource/images/refresh.svg",
"dark": "resource/images/refresh.svg"
}
},
{
"command": "qx-drafts.delete",
"title": "删除"
},
{
"command": "qx-drafts.rename",
"title": "重命名"
},
{
"command": "qx-drafts.createFile",
"title": "新建文件",
"icon": {
"light": "resource/images/newFile.svg",
"dark": "resource/images/newFile.svg"
}
},
{
"command": "qx-drafts.createFolder",
"title": "新建文件夹",
"icon": {
"light": "resource/images/newFolder.svg",
"dark": "resource/images/newFolder.svg"
}
},
{
"command": "qx-drafts.openInExplorer",
"title": "在资源管理器中打开",
"icon": {
"light": "resource/images/explorer.svg",
"dark": "resource/images/explorer.svg"
}
},
{
"command": "qx-drafts.openInTerminal",
"title": "在终端中打开",
"icon": {
"light": "resource/images/shell.svg",
"dark": "resource/images/shell.svg"
}
},
{
"command": "qx-drafts.openInNewWindow",
"title": "在新窗口打开",
"icon": {
"light": "resource/images/newWindow.svg",
"dark": "resource/images/newWindow.svg"
}
},
{
"command": "qx-drafts-list.addDrafts",
"title": "添加当前本地草稿本"
},
{
"command": "qx-drafts-list.deleteDrafts",
"title": "删除",
"icon": {
"light": "resource/images/delete.svg",
"dark": "resource/images/delete.svg"
}
},
{
"command": "qx-drafts-list.renameDrafts",
"title": "重命名",
"icon": {
"light": "resource/images/rename.svg",
"dark": "resource/images/rename.svg"
}
},
{
"command": "qx-drafts-list.addGithub",
"title": "添加当前GitHub远端草稿本"
},
{
"command": "qx-drafts-github.openFile",
"title": "打开github文件"
},
{
"command": "qx-drafts-github.createFile",
"title": "新建github文件",
"icon": {
"light": "resource/images/newFile.svg",
"dark": "resource/images/newFile.svg"
}
},
{
"command": "qx-drafts-github.refresh",
"title": "刷新",
"icon": {
"light": "resource/images/refresh.svg",
"dark": "resource/images/refresh.svg"
}
},
{
"command": "qx-drafts-github.deleteFile",
"title": "删除",
"icon": {
"light": "resource/images/delete.svg",
"dark": "resource/images/delete.svg"
}
},
{
"command": "qx-drafts-github.init",
"title": "初始化与选择"
},
{
"command": "qx-drafts-github.openInGithub",
"title": "在GitHub中打开",
"icon": {
"light": "resource/images/github.svg",
"dark": "resource/images/github.svg"
}
},
{
"command": "qx-drafts-github.clearCache",
"title": "清除当前仓库缓存"
},
{
"command": "qx-drafts-github.clearAllCache",
"title": "清除所有本地缓存"
},
{
"command": "qx-drafts-github.exit",
"title": "退出当前远端草稿本"
}
],
"configuration": {
"title": "草稿本Drafts",
"properties": {
"qx-drafts.folderPath": {
"type": "string",
"default": "",
"description": "草稿本路径"
},
"qx-drafts.token": {
"type": "string",
"default": "",
"description": "GitHub Personal Access Token"
},
"qx-drafts.username": {
"type": "string",
"default": "",
"description": "GitHub 用户名"
},
"qx-drafts.repo": {
"type": "string",
"default": "",
"description": "作为远端草稿本的 GitHub 仓库名"
}
}
},
"icons": {
"root-item-icon": {
"description": "root item",
"default": {
"fontPath": "./resource/icon/rootItem.woff",
"fontCharacter": "\\E900"
}
},
"qx-tip-icon": {
"description": "tip icon",
"default": {
"fontPath": "./resource/icon/tip.woff",
"fontCharacter": "\\E900"
}
}
}
},
"scripts": {
"vscode:prepublish": "npm run compile",
"compile": "tsc -p ./",
"watch": "tsc -watch -p ./",
"pretest": "npm run compile && npm run lint",
"lint": "eslint src --ext ts",
"test": "node ./out/test/runTest.js"
},
"devDependencies": {
"@types/mocha": "^10.0.1",
"@types/node": "16.x",
"@types/vscode": "^1.70.0",
"@typescript-eslint/eslint-plugin": "^6.4.1",
"@typescript-eslint/parser": "^6.4.1",
"@vscode/test-electron": "^2.3.4",
"eslint": "^8.47.0",
"glob": "^10.3.3",
"mocha": "^10.2.0",
"typescript": "^5.1.6"
},
"dependencies": {
"@octokit/rest": "^20.1.0"
}
}