coc-vscode-loader 1.2.8 → 1.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "converter",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.9",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "converter",
|
|
9
|
-
"version": "1.2.
|
|
9
|
+
"version": "1.2.9",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"commander": "^15.0.0",
|
|
12
12
|
"ts-morph": "^28.0.0",
|
package/converter/package.json
CHANGED
|
@@ -47,19 +47,7 @@ export const snippetsGenerator: StepGenerator = {
|
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
if (fileToLanguages.size === 0) {
|
|
50
|
-
|
|
51
|
-
// No paths resolved. Generate default paths from languages list so empty file
|
|
52
|
-
// fallback can create them later.
|
|
53
|
-
if (verbose) console.warn(' snippets: no paths resolved from contributedSnippets, using defaults')
|
|
54
|
-
for (const lang of ss.languages) {
|
|
55
|
-
const defaultPath = `./snippets/${lang}.json`
|
|
56
|
-
const langs = fileToLanguages.get(defaultPath) || []
|
|
57
|
-
langs.push(lang)
|
|
58
|
-
fileToLanguages.set(defaultPath, langs)
|
|
59
|
-
}
|
|
60
|
-
} else {
|
|
61
|
-
throw new Error('snippets step: no snippet files found to copy')
|
|
62
|
-
}
|
|
50
|
+
throw new Error('snippets step: no snippet files found to copy')
|
|
63
51
|
}
|
|
64
52
|
|
|
65
53
|
// Create output directories and copy files to original relative paths
|
|
@@ -73,7 +61,7 @@ export const snippetsGenerator: StepGenerator = {
|
|
|
73
61
|
for (const [sourceRelPath, languages] of fileToLanguages) {
|
|
74
62
|
const sourceFile = path.join(input, sourceRelPath)
|
|
75
63
|
if (!fs.existsSync(sourceFile)) {
|
|
76
|
-
|
|
64
|
+
console.warn(` snippets: source file not found: ${sourceFile}, skipping`)
|
|
77
65
|
continue
|
|
78
66
|
}
|
|
79
67
|
const dest = path.join(output, sourceRelPath)
|
|
@@ -105,21 +93,7 @@ export const snippetsGenerator: StepGenerator = {
|
|
|
105
93
|
}
|
|
106
94
|
|
|
107
95
|
if (copiedCount === 0) {
|
|
108
|
-
|
|
109
|
-
// so contributes.snippets references resolve correctly in the output package.json.
|
|
110
|
-
if (verbose) console.warn(' snippets: no snippet files found, generating empty files')
|
|
111
|
-
for (const [sourceRelPath, languages] of fileToLanguages) {
|
|
112
|
-
const dest = path.join(output, sourceRelPath)
|
|
113
|
-
if (fs.existsSync(dest)) continue
|
|
114
|
-
fs.mkdirSync(path.dirname(dest), { recursive: true })
|
|
115
|
-
fs.writeFileSync(dest, '{}')
|
|
116
|
-
copiedCount++
|
|
117
|
-
allLanguages.push(...languages)
|
|
118
|
-
if (verbose) console.log(` snippets: generated empty ${sourceRelPath}`)
|
|
119
|
-
}
|
|
120
|
-
if (copiedCount === 0) {
|
|
121
|
-
throw new Error('snippets step: no snippet files were copied and no languages configured')
|
|
122
|
-
}
|
|
96
|
+
throw new Error('snippets step: no snippet files were copied')
|
|
123
97
|
}
|
|
124
98
|
|
|
125
99
|
// Generate empty src/index.ts
|
package/lib/index.js
CHANGED
|
@@ -39,7 +39,7 @@ var require_package = __commonJS({
|
|
|
39
39
|
"package.json"(exports2, module2) {
|
|
40
40
|
module2.exports = {
|
|
41
41
|
name: "coc-vscode-loader",
|
|
42
|
-
version: "1.2.
|
|
42
|
+
version: "1.2.9",
|
|
43
43
|
description: "Run VS Code extensions seamlessly in coc.nvim",
|
|
44
44
|
main: "lib/index.js",
|
|
45
45
|
keywords: [
|