skillmds 1.2.0 → 1.2.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.
@@ -182,13 +182,14 @@ async function fetchBundle(base, slug, token, opts = {}) {
182
182
  let bytes = 0;
183
183
  for (const f of data.files) {
184
184
  let contents;
185
+ let fromUrl = false;
185
186
  if (f.content_base64 != null) {
186
187
  contents = Buffer.from(f.content_base64, "base64");
187
188
  } else if (f.source_url && isAllowedSourceUrl(f.source_url)) {
188
- if (!f.sha256) throw new IntegrityError(`"${f.path}" is delivered by URL but the registry recorded no sha256 for it \u2014 refusing to install unverifiable content`);
189
189
  const r = await doFetch(f.source_url).catch(() => null);
190
190
  if (!r || !r.ok) throw new Error(`could not fetch companion file "${f.path}" from ${hostOf(f.source_url)}`);
191
191
  contents = Buffer.from(await r.arrayBuffer());
192
+ fromUrl = true;
192
193
  } else {
193
194
  continue;
194
195
  }
@@ -197,10 +198,10 @@ async function fetchBundle(base, slug, token, opts = {}) {
197
198
  if (f.sha256) {
198
199
  const got = createHash("sha256").update(contents).digest("hex");
199
200
  if (got !== f.sha256) throw new IntegrityError(`integrity check failed for "${f.path}" (expected ${f.sha256.slice(0, 12)}\u2026, got ${got.slice(0, 12)}\u2026)`);
200
- } else if (f.path !== "SKILL.md") {
201
+ } else if (!fromUrl && f.path !== "SKILL.md") {
201
202
  throw new IntegrityError(`"${f.path}" has no sha256 in the registry bundle \u2014 refusing to install unverifiable content`);
202
203
  }
203
- out.push({ path: f.path, contents });
204
+ out.push({ path: f.path, contents, ...fromUrl && !f.sha256 ? { unverified: true } : {} });
204
205
  }
205
206
  return out;
206
207
  }
package/dist/cli.js CHANGED
@@ -30,7 +30,7 @@ import {
30
30
  uninstallSkill,
31
31
  upsertEntry,
32
32
  writeConfig
33
- } from "./chunk-A7BKAUUO.js";
33
+ } from "./chunk-4BFQJ3YZ.js";
34
34
 
35
35
  // src/index.ts
36
36
  import { Command as Command13 } from "commander";
@@ -662,6 +662,10 @@ async function promptAgentsInteractive(ctx) {
662
662
  });
663
663
  return p3.isCancel(picked) ? null : picked;
664
664
  }
665
+ function unverifiedFilesNote(n) {
666
+ const [f, it] = n === 1 ? ["file", "it"] : ["files", "them"];
667
+ return `${n} companion ${f} came straight from the source repo \u2014 the registry holds no checksum for ${it}, so only the connection was verified`;
668
+ }
665
669
  function registryFallbackNote(host) {
666
670
  return `installed from GitHub because the SkillMD registry (${host}) was unreachable \u2014 this copy is not the registry-reviewed version`;
667
671
  }
@@ -736,7 +740,13 @@ function makeDefaultDeps(flags) {
736
740
  const bundle = await fetchBundle(apiBase, registrySlug, token);
737
741
  if (bundle && bundle.length) {
738
742
  const sk = bundle.find((file) => file.path === "SKILL.md");
739
- return [{ ...meta, raw: sk ? sk.contents.toString("utf8") : skillMdFor(skill), files: bundle }];
743
+ const unverified = bundle.filter((file) => file.unverified).length;
744
+ return [{
745
+ ...meta,
746
+ raw: sk ? sk.contents.toString("utf8") : skillMdFor(skill),
747
+ files: bundle,
748
+ ...unverified ? { note: unverifiedFilesNote(unverified) } : {}
749
+ }];
740
750
  }
741
751
  const pack = await resolvePackFiles(skill);
742
752
  if (pack) return [{ ...meta, ...pack }];
package/dist/mcp.js CHANGED
@@ -12,7 +12,7 @@ import {
12
12
  safeText,
13
13
  stripTerminalEscapes,
14
14
  telemetryDisabled
15
- } from "./chunk-A7BKAUUO.js";
15
+ } from "./chunk-4BFQJ3YZ.js";
16
16
 
17
17
  // src/mcp/server.ts
18
18
  import { Server } from "@modelcontextprotocol/sdk/server/index.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "skillmds",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "SkillMD for agents: the `skillmds` MCP server + the `skillmd` CLI (lint, scan, search, install, publish Agent Skills) from skillmd.com.",
5
5
  "license": "MIT",
6
6
  "author": "SkillMD",