@modootoday/pmcp 0.1.0 → 0.1.1

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,6 +1,6 @@
1
1
  import {
2
2
  createSkillServer
3
- } from "./chunk-WIVQKKE4.js";
3
+ } from "./chunk-OPCK6D2H.js";
4
4
 
5
5
  // src/stdio.ts
6
6
  import { serveStdio } from "@modelcontextprotocol/server/stdio";
@@ -30,4 +30,4 @@ export {
30
30
  serve,
31
31
  main
32
32
  };
33
- //# sourceMappingURL=chunk-UTABV2C4.js.map
33
+ //# sourceMappingURL=chunk-DKZ2DN6U.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  normaliseIntent
3
- } from "./chunk-WIVQKKE4.js";
3
+ } from "./chunk-OPCK6D2H.js";
4
4
 
5
5
  // src/cache.ts
6
6
  async function openDatabase(path) {
@@ -131,4 +131,4 @@ export {
131
131
  DEFAULT_INTENT_CACHE_LIMIT,
132
132
  openIntentCache
133
133
  };
134
- //# sourceMappingURL=chunk-X3KWFZBP.js.map
134
+ //# sourceMappingURL=chunk-EXPHIDIV.js.map
@@ -338,7 +338,7 @@ function registerSkillTools(server, tools) {
338
338
  return server;
339
339
  }
340
340
  function createSkillServer(options) {
341
- const server = new McpServer({ name: SERVER_NAME, version: "0.1.0" });
341
+ const server = new McpServer({ name: SERVER_NAME, version: "0.1.1" });
342
342
  return registerSkillTools(server, createSkillTools(options));
343
343
  }
344
344
 
@@ -360,4 +360,4 @@ export {
360
360
  registerSkillTools,
361
361
  createSkillServer
362
362
  };
363
- //# sourceMappingURL=chunk-WIVQKKE4.js.map
363
+ //# sourceMappingURL=chunk-OPCK6D2H.js.map
package/dist/cli.js CHANGED
@@ -1,13 +1,13 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  openDatabase
4
- } from "./chunk-X3KWFZBP.js";
4
+ } from "./chunk-EXPHIDIV.js";
5
5
  import {
6
6
  serve
7
- } from "./chunk-UTABV2C4.js";
7
+ } from "./chunk-DKZ2DN6U.js";
8
8
  import {
9
9
  readCatalog
10
- } from "./chunk-WIVQKKE4.js";
10
+ } from "./chunk-OPCK6D2H.js";
11
11
 
12
12
  // src/cli/command.ts
13
13
  var ArgumentError = class extends Error {
@@ -453,6 +453,11 @@ var serveCommand = {
453
453
  }
454
454
  };
455
455
 
456
+ // src/cli/invocation.ts
457
+ function invocation(env = process.env) {
458
+ return env["npm_command"] === "exec" ? "npx -y @modootoday/pmcp" : "pmcp";
459
+ }
460
+
456
461
  // src/remote/session.ts
457
462
  import {
458
463
  chmodSync,
@@ -678,7 +683,10 @@ var loginCommand = {
678
683
  let interval = start.intervalMs;
679
684
  for (; ; ) {
680
685
  if (Date.now() >= start.expiresAt) {
681
- ui.error("expired", "the code timed out; run pmcp login again");
686
+ ui.error(
687
+ "expired",
688
+ `the code timed out; run ${invocation()} login again`
689
+ );
682
690
  return 1;
683
691
  }
684
692
  await wait(interval);
@@ -698,7 +706,10 @@ var loginCommand = {
698
706
  return 1;
699
707
  }
700
708
  if (outcome.kind === "expired") {
701
- ui.error("expired", "the code timed out; run pmcp login again");
709
+ ui.error(
710
+ "expired",
711
+ `the code timed out; run ${invocation()} login again`
712
+ );
702
713
  return 1;
703
714
  }
704
715
  }
@@ -744,7 +755,7 @@ var whoamiCommand = {
744
755
  `);
745
756
  } else {
746
757
  ui.data("not signed in\n");
747
- ui.info("sign in", "run pmcp login");
758
+ ui.info("sign in", `run ${invocation()} login`);
748
759
  }
749
760
  return 1;
750
761
  }
@@ -767,7 +778,8 @@ var whoamiCommand = {
767
778
  if (left !== void 0) {
768
779
  ui.data(
769
780
  left > 0 ? `token valid for ${String(answer.expiresInMinutes)} min
770
- ` : "token expired, run pmcp login\n"
781
+ ` : `token expired, run ${invocation()} login
782
+ `
771
783
  );
772
784
  }
773
785
  return 0;
@@ -1248,7 +1260,7 @@ var availableCommand = {
1248
1260
  if (matches.length > 0) {
1249
1261
  context.ui.info(
1250
1262
  "preview",
1251
- "pmcp preview <package> shows a full example before you subscribe"
1263
+ `${invocation()} preview <package> shows a full example before you subscribe`
1252
1264
  );
1253
1265
  }
1254
1266
  for (const issue of inventory.issues)
@@ -1718,7 +1730,9 @@ async function manage(context, sync) {
1718
1730
  }
1719
1731
  const session = readSession();
1720
1732
  if (!session || session.expiresAt !== void 0 && session.expiresAt <= Date.now()) {
1721
- throw new Error("run pmcp login before installing paid skill packages");
1733
+ throw new Error(
1734
+ `run ${invocation()} login before installing paid skill packages`
1735
+ );
1722
1736
  }
1723
1737
  const origin = apiOrigin(context);
1724
1738
  const credential2 = await issueDistributionCredential(
@@ -1862,7 +1876,7 @@ function dispatch(argv, options = {}) {
1862
1876
  }
1863
1877
  return run(command, rest, { ui, env, cwd });
1864
1878
  }
1865
- var VERSION = "0.1.0";
1879
+ var VERSION = "0.1.1";
1866
1880
  async function run(command, argv, context) {
1867
1881
  try {
1868
1882
  return await command.run({
package/dist/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  DEFAULT_INTENT_CACHE_LIMIT,
3
3
  openIntentCache
4
- } from "./chunk-X3KWFZBP.js";
4
+ } from "./chunk-EXPHIDIV.js";
5
5
  import {
6
6
  DEFAULT_FIND_LIMIT,
7
7
  MAX_SKILL_DEPTH,
@@ -19,7 +19,7 @@ import {
19
19
  readFrontmatter,
20
20
  registerSkillTools,
21
21
  withoutBody
22
- } from "./chunk-WIVQKKE4.js";
22
+ } from "./chunk-OPCK6D2H.js";
23
23
  export {
24
24
  DEFAULT_FIND_LIMIT,
25
25
  DEFAULT_INTENT_CACHE_LIMIT,
package/dist/stdio.js CHANGED
@@ -3,8 +3,8 @@ import {
3
3
  main,
4
4
  resolveRoots,
5
5
  serve
6
- } from "./chunk-UTABV2C4.js";
7
- import "./chunk-WIVQKKE4.js";
6
+ } from "./chunk-DKZ2DN6U.js";
7
+ import "./chunk-OPCK6D2H.js";
8
8
  export {
9
9
  main,
10
10
  resolveRoots,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@modootoday/pmcp",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "license": "Elastic-2.0",
5
5
  "author": "modootoday",
6
6
  "description": "An MCP server that finds the skills your installed packages already ship. Reads SKILL.md out of node_modules by shape rather than by path, so it sees the skills, .agent, .claude, .gemini and .codex conventions alike, and keeps session startup flat as the number of installed skills grows.",