@jakobm/peacekeeper 0.25.0 → 0.25.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.
- package/README.md +8 -1
- package/dist/package.json +3 -3
- package/dist/src/modules/cli/facade.js +1 -0
- package/dist/src/modules/cli/interface.js +1 -1
- package/dist/src/modules/configuration/facade.js +7 -0
- package/dist/src/modules/configuration/interface.js +1 -7
- package/dist/src/modules/dependencies.yaml +2 -2
- package/dist/src/modules/external.js +1 -0
- package/dist/src/modules/lifecycle/facade.js +7 -0
- package/dist/src/modules/lifecycle/interface.js +1 -7
- package/dist/src/modules/maintenance/facade.js +8 -0
- package/dist/src/modules/maintenance/interface.js +1 -8
- package/dist/src/modules/projects/facade.js +6 -0
- package/dist/src/modules/projects/generate-github-setup.js +1 -1
- package/dist/src/modules/projects/interface.js +1 -6
- package/dist/src/modules/releases/facade.js +11 -0
- package/dist/src/modules/releases/github-policy.js +1 -1
- package/dist/src/modules/releases/interface.js +1 -11
- package/dist/src/modules/testing/facade.js +5 -0
- package/dist/src/modules/testing/interface.js +1 -5
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -15,7 +15,9 @@ The flat module set consists of `cli`, `configuration`, `projects`, `testing`,
|
|
|
15
15
|
names to explicit operations on each domain's frozen facade. Modules
|
|
16
16
|
receive private factories, permitted module facades, and external services through
|
|
17
17
|
Portico injection; direct runtime imports inside the module tree are rejected by
|
|
18
|
-
the configured `portico check`.
|
|
18
|
+
the configured `portico check`. Each module declares its type-only contract in
|
|
19
|
+
`interface.ts` and exports its named `porticoFacade` factory from `facade.ts`.
|
|
20
|
+
Permitted dependencies are declared in
|
|
19
21
|
`src/modules/dependencies.yaml`. Cmdabra generates the CLI implementation contract
|
|
20
22
|
as `src/modules/cli/types.ts` from the root `cmdabra.yaml`; `npm run typecheck`
|
|
21
23
|
verifies that it is current before checking the TypeScript project.
|
|
@@ -27,6 +29,11 @@ Checkpoint and session lifecycle hooks use the same Cmdabra and Portico composit
|
|
|
27
29
|
as other CLI commands. Dependencies must therefore be installed in every worktree
|
|
28
30
|
before its hooks run; the required Codex environment setup performs `npm ci`.
|
|
29
31
|
|
|
32
|
+
The CLI also exposes Cmdabra's global `--cmdabra-complete` option for
|
|
33
|
+
[shell completion adapters](https://github.com/jakobmattsson/cmdabra#shell-completion).
|
|
34
|
+
It accepts the current word index followed by all command-line words and prints
|
|
35
|
+
completion candidates without running a command.
|
|
36
|
+
|
|
30
37
|
## Create a compliant TypeScript project
|
|
31
38
|
|
|
32
39
|
`create-project` creates a minimal ESM TypeScript library in an existing, completely
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jakobm/peacekeeper",
|
|
3
|
-
"version": "0.25.
|
|
3
|
+
"version": "0.25.1",
|
|
4
4
|
"description": "Shared repository test, Git worktree, and Codex hook commands",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Jakob Mattsson",
|
|
@@ -41,8 +41,8 @@
|
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
43
|
"@iarna/toml": "^2.2.5",
|
|
44
|
-
"@jakobm/cmdabra": "^0.
|
|
45
|
-
"@jakobm/portico": "^0.
|
|
44
|
+
"@jakobm/cmdabra": "^0.7.0",
|
|
45
|
+
"@jakobm/portico": "^0.8.1",
|
|
46
46
|
"semver": "^7.8.5",
|
|
47
47
|
"yaml": "^2.9.1"
|
|
48
48
|
},
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const porticoFacade = ({ service }) => ({ run: service.run });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export const porticoFacade = ({ projectConfig, updateConfig }) => ({
|
|
2
|
+
projectConfig: projectConfig.projectConfig,
|
|
3
|
+
repositoryRoot: projectConfig.repositoryRoot,
|
|
4
|
+
requireTestCommands: projectConfig.requireTestCommands,
|
|
5
|
+
validateConfig: projectConfig.validateConfig,
|
|
6
|
+
updateConfig: updateConfig.run,
|
|
7
|
+
});
|
|
@@ -1,7 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
projectConfig: projectConfig.projectConfig,
|
|
3
|
-
repositoryRoot: projectConfig.repositoryRoot,
|
|
4
|
-
requireTestCommands: projectConfig.requireTestCommands,
|
|
5
|
-
validateConfig: projectConfig.validateConfig,
|
|
6
|
-
updateConfig: updateConfig.run,
|
|
7
|
-
});
|
|
1
|
+
export {};
|
|
@@ -11,6 +11,6 @@ allowed-external:
|
|
|
11
11
|
configuration: [execFileSync, fs, isDeepStrictEqual, output, path, projectConfigDefaults, runtime, YAML]
|
|
12
12
|
lifecycle: [buffer, clock, executablePath, fs, output, path, runtime, spawn, spawnSync]
|
|
13
13
|
maintenance: [execFileSync, fs, output, path, runtime, spawnSync]
|
|
14
|
-
projects: [buffer, fs, isDeepStrictEqual, modulesRoot, output, packageVersion, path, projectConfigDefaults, runtime, semver, spawnSync, TOML, url, YAML]
|
|
15
|
-
releases: [assessReleaseSchema, clock, execFileSync, fs, modulesRoot, os, output, path, runtime, semver, spawnSync, url, YAML]
|
|
14
|
+
projects: [buffer, fs, isDeepStrictEqual, modulesRoot, output, packageVersion, path, projectConfigDefaults, runtime, semver, spawnSync, structuredClone, TOML, url, YAML]
|
|
15
|
+
releases: [assessReleaseSchema, clock, execFileSync, fs, modulesRoot, os, output, path, runtime, semver, spawnSync, structuredClone, url, YAML]
|
|
16
16
|
testing: [clock, crypto, execFileSync, fs, modulesRoot, os, output, path, runtime, spawnSync]
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export const porticoFacade = ({ checkpointCodexChanges, checkpointCodexSessionStart, checkpointCodexStop, cleanupEndedSession, queueMergedWorktreeCleanup }) => ({
|
|
2
|
+
checkpointCodexChanges: checkpointCodexChanges.run,
|
|
3
|
+
checkpointCodexSessionStart: checkpointCodexSessionStart.run,
|
|
4
|
+
checkpointCodexStop: checkpointCodexStop.run,
|
|
5
|
+
cleanupEndedSession: cleanupEndedSession.run,
|
|
6
|
+
queueMergedWorktreeCleanup: queueMergedWorktreeCleanup.run,
|
|
7
|
+
});
|
|
@@ -1,7 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
checkpointCodexChanges: checkpointCodexChanges.run,
|
|
3
|
-
checkpointCodexSessionStart: checkpointCodexSessionStart.run,
|
|
4
|
-
checkpointCodexStop: checkpointCodexStop.run,
|
|
5
|
-
cleanupEndedSession: cleanupEndedSession.run,
|
|
6
|
-
queueMergedWorktreeCleanup: queueMergedWorktreeCleanup.run,
|
|
7
|
-
});
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export const porticoFacade = ({ cleanupMergedBranches, initializeCodexWorktree, removeEmptyDirectories }) => ({
|
|
2
|
+
applyPlan: cleanupMergedBranches.applyPlan,
|
|
3
|
+
buildPlan: cleanupMergedBranches.buildPlan,
|
|
4
|
+
cleanupMergedBranches: cleanupMergedBranches.run,
|
|
5
|
+
initializeCodexWorktree: initializeCodexWorktree.main,
|
|
6
|
+
listWorktrees: cleanupMergedBranches.listWorktrees,
|
|
7
|
+
removeEmptyDirectories: removeEmptyDirectories.main,
|
|
8
|
+
});
|
|
@@ -1,8 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
applyPlan: cleanupMergedBranches.applyPlan,
|
|
3
|
-
buildPlan: cleanupMergedBranches.buildPlan,
|
|
4
|
-
cleanupMergedBranches: cleanupMergedBranches.run,
|
|
5
|
-
initializeCodexWorktree: initializeCodexWorktree.main,
|
|
6
|
-
listWorktrees: cleanupMergedBranches.listWorktrees,
|
|
7
|
-
removeEmptyDirectories: removeEmptyDirectories.main,
|
|
8
|
-
});
|
|
1
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export default ({ configuration, createProjectCore, external: { buffer: Buffer, projectConfigDefaults, runtime, spawnSync, YAML, } }) => {
|
|
1
|
+
export default ({ configuration, createProjectCore, external: { buffer: Buffer, projectConfigDefaults, runtime, spawnSync, structuredClone, YAML, } }) => {
|
|
2
2
|
const { validateConfig } = configuration;
|
|
3
3
|
const { githubSetup, repositoryIdentity } = createProjectCore;
|
|
4
4
|
function api(endpoint, missingAllowed = false) {
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export const porticoFacade = ({ assessRelease, githubPolicy, release, releaseCore, verifyRelease, verifyReleaseProtection, verifyReleaseVersion }) => ({
|
|
2
|
+
assessRelease: assessRelease.run,
|
|
3
|
+
createGithubPolicy: githubPolicy.createGithubPolicy,
|
|
4
|
+
ensureLockfilesMatch: releaseCore.ensureLockfilesMatch,
|
|
5
|
+
githubSetupPlan: githubPolicy.setupPlan,
|
|
6
|
+
inspectWorkflow: releaseCore.inspectWorkflow,
|
|
7
|
+
release: release.run,
|
|
8
|
+
verifyRelease: verifyRelease.run,
|
|
9
|
+
verifyReleaseProtection: verifyReleaseProtection.run,
|
|
10
|
+
verifyReleaseVersion: verifyReleaseVersion.run,
|
|
11
|
+
});
|
|
@@ -1,11 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
assessRelease: assessRelease.run,
|
|
3
|
-
createGithubPolicy: githubPolicy.createGithubPolicy,
|
|
4
|
-
ensureLockfilesMatch: releaseCore.ensureLockfilesMatch,
|
|
5
|
-
githubSetupPlan: githubPolicy.setupPlan,
|
|
6
|
-
inspectWorkflow: releaseCore.inspectWorkflow,
|
|
7
|
-
release: release.run,
|
|
8
|
-
verifyRelease: verifyRelease.run,
|
|
9
|
-
verifyReleaseProtection: verifyReleaseProtection.run,
|
|
10
|
-
verifyReleaseVersion: verifyReleaseVersion.run,
|
|
11
|
-
});
|
|
1
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jakobm/peacekeeper",
|
|
3
|
-
"version": "0.25.
|
|
3
|
+
"version": "0.25.1",
|
|
4
4
|
"description": "Shared repository test, Git worktree, and Codex hook commands",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Jakob Mattsson",
|
|
@@ -41,8 +41,8 @@
|
|
|
41
41
|
},
|
|
42
42
|
"dependencies": {
|
|
43
43
|
"@iarna/toml": "^2.2.5",
|
|
44
|
-
"@jakobm/cmdabra": "^0.
|
|
45
|
-
"@jakobm/portico": "^0.
|
|
44
|
+
"@jakobm/cmdabra": "^0.7.0",
|
|
45
|
+
"@jakobm/portico": "^0.8.1",
|
|
46
46
|
"semver": "^7.8.5",
|
|
47
47
|
"yaml": "^2.9.1"
|
|
48
48
|
},
|