@steinscheng/zhaotongkuan 0.8.6 → 0.8.7

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@steinscheng/zhaotongkuan",
3
- "version": "0.8.6",
3
+ "version": "0.8.7",
4
4
  "description": "Small, verifiable installer bootstrap for the Zhaotongkuan Codex plugin",
5
5
  "type": "module",
6
6
  "bin": {
@@ -11,6 +11,7 @@
11
11
  "src/cli.js",
12
12
  "src/extract_installer.py",
13
13
  "src/release-channel.json",
14
+ "src/releases/*.zip",
14
15
  "README.md",
15
16
  "LICENSE.txt"
16
17
  ],
package/src/cli.js CHANGED
@@ -410,7 +410,15 @@ export async function main(argv) {
410
410
  temporary = mkdtempSync(join(tmpdir(), "zhaotongkuan-bootstrap-"));
411
411
  await mkdir(temporary, { recursive: true });
412
412
  const archiveDestination = join(temporary, basename(new URL(release.archive, "file:///").pathname) || "release.zip");
413
- const archivePath = await acquireArchive(release.archive, archiveDestination, release.repository);
413
+ // The public npm package may carry the exact release ZIP. Prefer it so
414
+ // customers do not need GitHub/gh access; the trusted SHA check remains
415
+ // mandatory. GitHub remains a fallback for older or development packages.
416
+ const embeddedArchive = join(PACKAGE_ROOT, "src", "releases", basename(archiveDestination));
417
+ const archivePath = await acquireArchive(
418
+ existsSync(embeddedArchive) ? embeddedArchive : release.archive,
419
+ archiveDestination,
420
+ release.repository,
421
+ );
414
422
  await verifyArchive(archivePath, release.expectedSha256);
415
423
 
416
424
  const installerPath = join(temporary, "agent_install.py");
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "schema_version": 1,
3
3
  "repository": "SchengSteins/zhaotongkuan",
4
- "version": "0.8.6",
4
+ "version": "0.8.7",
5
5
  "artifacts": {
6
6
  "any": {
7
- "url": "https://github.com/SchengSteins/zhaotongkuan/releases/download/v0.8.6/zhaotongkuan-0.8.6.zip",
8
- "sha256": "66280990333494433feca4a5efbd0981840b5e57e70ab82126c09044ff40ea0d"
7
+ "url": "https://github.com/SchengSteins/zhaotongkuan/releases/download/v0.8.7/zhaotongkuan-0.8.7.zip",
8
+ "sha256": "b34349fe141578d7f872bff5b880ee175cfa6993c17a6cf878362e6be0e2b95d"
9
9
  }
10
10
  }
11
11
  }