更新部分内容

This commit is contained in:
zhuo.quan 2024-07-05 15:51:39 +08:00
parent 3b2c2c1510
commit 219391810a
3 changed files with 8 additions and 9 deletions

View File

@ -58,7 +58,7 @@ class KylinIdePackage extends PackageStep {
} }
modifyPackageJson() { modifyPackageJson() {
this.packageJsonData.downloadUrl = 'https://gitee.com/openKylin/extensions-repo/tree/master/KylinIDETeam/cmake-intellisence'; this.packageJsonData.downloadUrl = 'https://gitee.com/openkylin/cmake-intellisence/releases';
this.packageJsonData.keywords = [ this.packageJsonData.keywords = [
"KylinIdeDev", "KylinIdeDev",
"KylinIdeDevEdit", "KylinIdeDevEdit",

View File

@ -4,7 +4,7 @@
"description": "Language Client for CMake IntelliSence extension", "description": "Language Client for CMake IntelliSence extension",
"author": "quanzhuo", "author": "quanzhuo",
"license": "MIT", "license": "MIT",
"publisher": "openKylin", "publisher": "KylinIdeTeam",
"engines": { "engines": {
"vscode": "^1.68.0" "vscode": "^1.68.0"
}, },

View File

@ -1,15 +1,14 @@
import { stat } from 'node:fs/promises';
import * as path from 'path'; import * as path from 'path';
import { getConfigLogLevel, Logger } from './logging'; import { commands, ExtensionContext, window, workspace } from 'vscode';
import { workspace, ExtensionContext, window, commands } from 'vscode';
import { import {
LanguageClient, LanguageClient,
LanguageClientOptions, LanguageClientOptions,
ServerOptions, ServerOptions,
TransportKind TransportKind
} from 'vscode-languageclient/node'; } from 'vscode-languageclient/node';
import { existsSync } from 'fs';
import { stat } from 'node:fs/promises';
import * as which from 'which'; import * as which from 'which';
import { getConfigLogLevel, Logger } from './logging';
export const SERVER_ID = 'cmakeIntelliSence'; export const SERVER_ID = 'cmakeIntelliSence';
@ -17,7 +16,7 @@ export const SERVER_NAME = 'CMake Language Server';
let client: LanguageClient; let client: LanguageClient;
async function checkCMakeExecutable(cmakePath: string) : Promise<boolean> { async function checkCMakeExecutable(cmakePath: string): Promise<boolean> {
try { try {
await stat(cmakePath); await stat(cmakePath);
} catch (error) { } catch (error) {
@ -60,7 +59,7 @@ export async function activate(context: ExtensionContext) {
if (e.affectsConfiguration(`${SERVER_ID}.cmakePath`)) { if (e.affectsConfiguration(`${SERVER_ID}.cmakePath`)) {
const cmakePath = workspace.getConfiguration(SERVER_ID).get<string>('cmakePath'); const cmakePath = workspace.getConfiguration(SERVER_ID).get<string>('cmakePath');
if (! client?.isRunning()) { if (!client?.isRunning()) {
checkAndStart(cmakePath); checkAndStart(cmakePath);
} }
} }