monoforge 0.9.0 → 1.0.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.
- package/README.md +1 -1
- package/bin/forge.mjs +34 -1
- package/package.json +12 -5
- package/packs/README.md +62 -0
- package/packs/public/forge-shapes/index.mjs +161 -0
- package/packs/public/forge-shapes/pack.json +13 -0
- package/packs/public/forge-shapes/test/fixtures/bad-publish/.github/workflows/publish.yml +11 -0
- package/packs/public/forge-shapes/test/fixtures/bad-publish/.monoforge-stamp.json +12 -0
- package/packs/public/forge-shapes/test/fixtures/bad-publish/README.md +3 -0
- package/packs/public/forge-shapes/test/fixtures/bad-publish/bin/probe.mjs +2 -0
- package/packs/public/forge-shapes/test/fixtures/bad-publish/package.json +14 -0
- package/packs/public/forge-shapes/test/fixtures/clean/.github/workflows/publish.yml +12 -0
- package/packs/public/forge-shapes/test/fixtures/clean/.monoforge-stamp.json +12 -0
- package/packs/public/forge-shapes/test/fixtures/clean/README.md +3 -0
- package/packs/public/forge-shapes/test/fixtures/clean/bin/probe.mjs +2 -0
- package/packs/public/forge-shapes/test/fixtures/clean/package.json +14 -0
- package/packs/public/forge-shapes/test/fixtures/missing-file/.github/workflows/publish.yml +12 -0
- package/packs/public/forge-shapes/test/fixtures/missing-file/.monoforge-stamp.json +13 -0
- package/packs/public/forge-shapes/test/fixtures/missing-file/README.md +3 -0
- package/packs/public/forge-shapes/test/fixtures/missing-file/bin/probe.mjs +2 -0
- package/packs/public/forge-shapes/test/fixtures/missing-file/package.json +14 -0
- package/packs/public/forge-shapes/test/fixtures/token/.github/workflows/publish.yml +12 -0
- package/packs/public/forge-shapes/test/fixtures/token/.monoforge-stamp.json +12 -0
- package/packs/public/forge-shapes/test/fixtures/token/README.md +3 -0
- package/packs/public/forge-shapes/test/fixtures/token/bin/probe.mjs +2 -0
- package/packs/public/forge-shapes/test/fixtures/token/package.json +14 -0
- package/packs/public/forge-shapes/test/fixtures/unfilled/.github/workflows/publish.yml +12 -0
- package/packs/public/forge-shapes/test/fixtures/unfilled/.monoforge-stamp.json +12 -0
- package/packs/public/forge-shapes/test/fixtures/unfilled/README.md +3 -0
- package/packs/public/forge-shapes/test/fixtures/unfilled/bin/probe.mjs +2 -0
- package/packs/public/forge-shapes/test/fixtures/unfilled/package.json +14 -0
- package/packs/public/forge-shapes/test/run.mjs +67 -0
- package/spec/refusals.json +35 -0
- package/src/doctor.mjs +46 -23
- package/src/fs-adapter.mjs +143 -0
- package/src/fs-node.mjs +15 -0
- package/src/harness.mjs +118 -0
- package/src/index.mjs +16 -1
- package/src/lock.mjs +1 -1
- package/src/packs.mjs +200 -0
- package/src/paths.mjs +48 -0
- package/src/refusals.mjs +45 -0
- package/src/sha256.mjs +61 -0
- package/src/stamp.mjs +64 -50
- package/src/templates.mjs +28 -14
- package/src/workers.mjs +16 -0
package/src/workers.mjs
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
// src/workers.mjs - the workers-native surface (monoforge#27).
|
|
2
|
+
//
|
|
3
|
+
// The coreforge rig vendored a fork of the stamp engine because workerd has no
|
|
4
|
+
// `node:fs`. This module is the surface that retires the fork: the stamp engine
|
|
5
|
+
// plus the storage adapters, with NO import that reaches `node:fs` statically.
|
|
6
|
+
// A Cloudflare Worker imports this, seeds its templates into `memoryFs()`, and
|
|
7
|
+
// calls `stamp(dir, { fs, root })` - the same truth machinery as Node, only the
|
|
8
|
+
// storage differs.
|
|
9
|
+
//
|
|
10
|
+
// Unlike `src/index.mjs`, this surface deliberately omits `doctor` and `lock`
|
|
11
|
+
// (they shell out to git and use `node:fs`); a worker that wants the battery
|
|
12
|
+
// runs it in Node. The engine (`stamp`) and the adapters are what the runtime
|
|
13
|
+
// boundary needs.
|
|
14
|
+
export { default as stamp, readFactoryConfig, tokenReplacements, stampToolName, sha256, RECEIPT } from './stamp.mjs'
|
|
15
|
+
export { memoryFs, FS_ADAPTER_METHODS, setDefaultFs, getDefaultFs } from './fs-adapter.mjs'
|
|
16
|
+
export { resolveTemplate, resolveChain, TEMPLATES } from './templates.mjs'
|