coc-vscode-loader 1.2.9 → 1.3.0
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.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "converter",
|
|
9
|
-
"version": "1.
|
|
9
|
+
"version": "1.3.0",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"commander": "^15.0.0",
|
|
12
12
|
"ts-morph": "^28.0.0",
|
package/converter/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "converter",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"private": true,
|
|
5
|
-
"description": "vscode
|
|
5
|
+
"description": "vscode \u2192 coc.nvim converter prototype",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"scripts": {
|
|
8
8
|
"convert": "tsx src/cli.ts"
|
|
@@ -93,7 +93,7 @@ import * as path from 'path'
|
|
|
93
93
|
export async function activate(context: ExtensionContext): Promise<void> {
|
|
94
94
|
try {
|
|
95
95
|
${ls.verbose ? ` console.log('[${escapeStr(id)}] activate() called')\n` : ''}${serverPathCode}
|
|
96
|
-
if (!serverPath) {
|
|
96
|
+
if (!serverPath && !_mainEntry) {
|
|
97
97
|
${ls.verbose ? ` console.log('[${escapeStr(id)}] serverPath undefined')\n` : ''}\
|
|
98
98
|
window.showErrorMessage('Cannot find language server.')
|
|
99
99
|
return
|
|
@@ -75,9 +75,18 @@ export const snippetsGenerator: StepGenerator = {
|
|
|
75
75
|
if (copiedCount === 0 && ss.build) {
|
|
76
76
|
// Run build script to generate snippet files (e.g. node merge.js)
|
|
77
77
|
if (verbose) console.log(` snippets: running build: ${ss.build}`)
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
78
|
+
try {
|
|
79
|
+
execFileSync('npm', ['install', '--legacy-peer-deps'], { cwd: input, stdio: verbose ? 'inherit' : 'pipe' })
|
|
80
|
+
const [cmd, ...args] = ss.build.split(' ')
|
|
81
|
+
execFileSync(cmd, args, { cwd: input, stdio: verbose ? 'inherit' : 'pipe' })
|
|
82
|
+
} catch (e: any) {
|
|
83
|
+
if (e.code === 'ENOENT') {
|
|
84
|
+
const cmd = ss.build.split(' ')[0]
|
|
85
|
+
console.warn(` snippets: build tool "${cmd}" not found. Install it and try again, or remove the "build" field from the registry entry.`)
|
|
86
|
+
} else {
|
|
87
|
+
console.warn(` snippets: build failed (${e.message}), skipping`)
|
|
88
|
+
}
|
|
89
|
+
}
|
|
81
90
|
// Retry copying
|
|
82
91
|
for (const [sourceRelPath, languages] of fileToLanguages) {
|
|
83
92
|
const sourceFile = path.join(input, sourceRelPath)
|
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.
|
|
42
|
+
version: "1.3.0",
|
|
43
43
|
description: "Run VS Code extensions seamlessly in coc.nvim",
|
|
44
44
|
main: "lib/index.js",
|
|
45
45
|
keywords: [
|