@yaegassy/coc-marksman 0.3.9 → 0.4.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.
Files changed (2) hide show
  1. package/lib/index.js +15 -13
  2. package/package.json +2 -2
package/lib/index.js CHANGED
@@ -3220,7 +3220,7 @@ var import_stream2 = __toESM(require("stream"));
3220
3220
  var import_util = require("util");
3221
3221
 
3222
3222
  // package.json
3223
- var marksmanBinVersion = "2023-11-29";
3223
+ var marksmanBinVersion = "2023-12-09";
3224
3224
 
3225
3225
  // src/constant.ts
3226
3226
  var MARKSMAN_BIN_VERSION = marksmanBinVersion;
@@ -3238,7 +3238,7 @@ var statusNotificationType = new import_coc.NotificationType("marksman/status");
3238
3238
  var ExperimentalFeatures = class {
3239
3239
  fillClientCapabilities(capabilities) {
3240
3240
  const experimental = capabilities.experimental ?? {};
3241
- experimental.codeLensShowReferences = true;
3241
+ experimental.codeLensFindReferences = true;
3242
3242
  experimental.followLinks = true;
3243
3243
  experimental.statusNotification = true;
3244
3244
  capabilities.experimental = experimental;
@@ -3269,10 +3269,16 @@ async function activate(context) {
3269
3269
  outputchannel.show(true);
3270
3270
  }
3271
3271
  });
3272
+ const findReferencesCmd = import_coc.commands.registerCommand(`${extId}.findReferences`, findReferencesCmdImpl, null, true);
3272
3273
  if (client) {
3273
3274
  context.subscriptions.push(client.start());
3274
3275
  }
3275
- context.subscriptions.push(restartServerCmd, showOutputCmd);
3276
+ context.subscriptions.push(restartServerCmd, showOutputCmd, findReferencesCmd);
3277
+ }
3278
+ async function findReferencesCmdImpl(data) {
3279
+ if (client) {
3280
+ await import_coc.commands.executeCommand("editor.action.showReferences", import_coc.Uri.parse(data.uri), data.position, data.locations);
3281
+ }
3276
3282
  }
3277
3283
  async function connectToServer(context, status) {
3278
3284
  let serverOptions;
@@ -3334,20 +3340,16 @@ function serverBinName() {
3334
3340
  function releaseBinName() {
3335
3341
  const platform = import_os.default.platform();
3336
3342
  const arch = import_os.default.arch();
3337
- if (platform === "win32") {
3343
+ if (platform === "win32" && arch === "x64") {
3338
3344
  return "marksman.exe";
3339
3345
  } else if (platform === "darwin") {
3340
3346
  return "marksman-macos";
3341
- } else if (platform === "linux") {
3342
- if (arch === "x64") {
3343
- return "marksman-linux-x64";
3344
- } else if (arch === "arm64") {
3345
- return "marksman-linux-arm64";
3346
- } else {
3347
- throw new Error(`Unsupported ${arch} ${platform}`);
3348
- }
3347
+ } else if (platform === "linux" && arch === "x64") {
3348
+ return "marksman-linux-x64";
3349
+ } else if (platform === "linux" && arch === "arm64") {
3350
+ return "marksman-linux-arm64";
3349
3351
  } else {
3350
- throw new Error(`Unsupported ${arch} ${platform}`);
3352
+ throw new Error(`Unsupported platform: ${platform}`);
3351
3353
  }
3352
3354
  }
3353
3355
  function releaseDownloadUrl() {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@yaegassy/coc-marksman",
3
- "version": "0.3.9",
4
- "marksmanBinVersion": "2023-11-29",
3
+ "version": "0.4.0",
4
+ "marksmanBinVersion": "2023-12-09",
5
5
  "description": "Marksman (Markdown LSP server) extension for coc.nvim",
6
6
  "author": "yaegassy <yosstools@gmail.com>",
7
7
  "license": "MIT",