@pulse-compute/cli 0.0.0 → 1.0.0-beta.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/API.md +539 -0
- package/CHANGELOG.md +47 -0
- package/README.md +70 -1
- package/bin/pulse.js +15 -0
- package/bin/pulsewasm-extract.js +22 -0
- package/cli-spec.json +575 -0
- package/completions/_pulse +106 -0
- package/completions/pulse.bash +31 -0
- package/completions/pulse.fish +76 -0
- package/docs/README.md +77 -0
- package/docs/architecture/current-contracts.md +381 -0
- package/docs/architecture/overview.md +93 -0
- package/docs/architecture/vision.md +515 -0
- package/docs/concepts/bodies.md +186 -0
- package/docs/concepts/compilation-and-lowering.md +496 -0
- package/docs/concepts/contracts-and-providers.md +158 -0
- package/docs/concepts/effects-and-continuations.md +243 -0
- package/docs/concepts/entities-and-adapters.md +71 -0
- package/docs/concepts/package-owned-lowering.md +175 -0
- package/docs/concepts/targets-and-hosts.md +62 -0
- package/docs/contributing/README.md +38 -0
- package/docs/contributing/adding-core-provider.md +315 -0
- package/docs/contributing/adding-first-party-lowerer.md +327 -0
- package/docs/contributing/entities-lowering.md +91 -0
- package/docs/contributing/package-lowerer-contract.md +383 -0
- package/docs/contributing/pulse-aware-packages.md +149 -0
- package/docs/examples.md +112 -0
- package/docs/fixtures/inspect-fetch-composition.selected.json +181 -0
- package/docs/getting-started.md +128 -0
- package/docs/guides/compatibility-imports.md +60 -0
- package/docs/guides/deploying-fastly.md +188 -0
- package/docs/guides/deploying-node.md +143 -0
- package/docs/guides/events.md +233 -0
- package/docs/guides/fastly-capabilities.md +153 -0
- package/docs/guides/fetching-and-composition.md +101 -0
- package/docs/guides/grip.md +94 -0
- package/docs/guides/json-schemas.md +233 -0
- package/docs/guides/migrating-from-express.md +192 -0
- package/docs/guides/project-lifecycle.md +143 -0
- package/docs/guides/routing.md +184 -0
- package/docs/guides/troubleshooting.md +47 -0
- package/docs/maintainers/README.md +60 -0
- package/docs/maintainers/codex-maintainer.md +71 -0
- package/docs/maintainers/documentation-deployment.md +147 -0
- package/docs/maintainers/documentation-system.md +58 -0
- package/docs/maintainers/documentation-versioning.md +65 -0
- package/docs/maintainers/maintainer-charter.md +84 -0
- package/docs/maintainers/maintenance-policy.json +778 -0
- package/docs/maintainers/maintenance-policy.md +124 -0
- package/docs/maintainers/npm-publishing.md +154 -0
- package/docs/maintainers/plugin-readiness.json +19 -0
- package/docs/maintainers/plugin-readiness.md +31 -0
- package/docs/maintainers/public-site.md +158 -0
- package/docs/maintainers/release-acceptance.md +250 -0
- package/docs/maintainers/release-manifest.md +88 -0
- package/docs/maintainers/repository-setup.md +145 -0
- package/docs/maintainers/scope-policy.md +93 -0
- package/docs/maintainers/support-and-triage.md +74 -0
- package/docs/maintainers/testing.md +288 -0
- package/docs/packages/README.md +59 -0
- package/docs/packages/assets.md +85 -0
- package/docs/packages/cli.md +190 -0
- package/docs/packages/crypto.md +71 -0
- package/docs/packages/entities.md +129 -0
- package/docs/packages/grip.md +82 -0
- package/docs/packages/implementation-packages.md +113 -0
- package/docs/packages/jwt.md +55 -0
- package/docs/packages/provider-fastly.md +217 -0
- package/docs/packages/pulse.md +159 -0
- package/docs/packages/runtime.md +256 -0
- package/docs/preview-scope.md +142 -0
- package/docs/reference/README.md +33 -0
- package/docs/reference/cli-spec.json +575 -0
- package/docs/reference/cli.md +457 -0
- package/docs/reference/compatibility-matrix.md +169 -0
- package/docs/reference/diagnostics.md +1872 -0
- package/docs/reference/documentation-versions.json +14 -0
- package/docs/reference/environment.md +347 -0
- package/docs/reference/handler-authoring.md +264 -0
- package/docs/reference/project-config.md +554 -0
- package/docs/reference/project-config.schema.json +918 -0
- package/docs/reference/release-manifest.json +427 -0
- package/docs/reference/shell-completion.md +23 -0
- package/documentation-site.json +661 -0
- package/documentation-versions.json +14 -0
- package/examples/01-hello-json/.pulse/.gitignore +3 -0
- package/examples/01-hello-json/.pulse/config.ts +16 -0
- package/examples/01-hello-json/README.md +119 -0
- package/examples/01-hello-json/package.json +20 -0
- package/examples/01-hello-json/src/index.ts +9 -0
- package/examples/01-hello-json/tests/pulse.harness.ts +22 -0
- package/examples/01-hello-json/tsconfig.json +14 -0
- package/examples/02-request-schema/.pulse/.gitignore +3 -0
- package/examples/02-request-schema/.pulse/config.ts +17 -0
- package/examples/02-request-schema/README.md +145 -0
- package/examples/02-request-schema/package.json +20 -0
- package/examples/02-request-schema/src/index.ts +18 -0
- package/examples/02-request-schema/src/schemas.ts +20 -0
- package/examples/02-request-schema/tests/pulse.harness.ts +37 -0
- package/examples/02-request-schema/tsconfig.json +14 -0
- package/examples/03-fetch-composition/.pulse/.gitignore +3 -0
- package/examples/03-fetch-composition/.pulse/config.ts +31 -0
- package/examples/03-fetch-composition/README.md +210 -0
- package/examples/03-fetch-composition/package.json +20 -0
- package/examples/03-fetch-composition/src/index.ts +60 -0
- package/examples/03-fetch-composition/tests/pulse.harness.ts +47 -0
- package/examples/03-fetch-composition/tsconfig.json +14 -0
- package/examples/05-fastly-capabilities/.pulse/.gitignore +3 -0
- package/examples/05-fastly-capabilities/.pulse/config.ts +57 -0
- package/examples/05-fastly-capabilities/README.md +257 -0
- package/examples/05-fastly-capabilities/package.json +22 -0
- package/examples/05-fastly-capabilities/src/index.ts +55 -0
- package/examples/05-fastly-capabilities/tests/pulse.harness.ts +66 -0
- package/examples/05-fastly-capabilities/tsconfig.json +14 -0
- package/examples/07-opaque-proxy/.pulse/.gitignore +3 -0
- package/examples/07-opaque-proxy/.pulse/config.ts +38 -0
- package/examples/07-opaque-proxy/README.md +150 -0
- package/examples/07-opaque-proxy/package.json +21 -0
- package/examples/07-opaque-proxy/src/index.ts +9 -0
- package/examples/07-opaque-proxy/tests/pulse.harness.ts +25 -0
- package/examples/07-opaque-proxy/tsconfig.json +14 -0
- package/examples/09-router-lowering/.pulse/.gitignore +3 -0
- package/examples/09-router-lowering/.pulse/config.ts +22 -0
- package/examples/09-router-lowering/README.md +287 -0
- package/examples/09-router-lowering/package.json +22 -0
- package/examples/09-router-lowering/src/index.ts +65 -0
- package/examples/09-router-lowering/tests/pulse.harness.ts +91 -0
- package/examples/09-router-lowering/tsconfig.json +14 -0
- package/examples/10-entities-tools/.pulse/.gitignore +4 -0
- package/examples/10-entities-tools/.pulse/config.ts +23 -0
- package/examples/10-entities-tools/README.md +165 -0
- package/examples/10-entities-tools/package.json +21 -0
- package/examples/10-entities-tools/src/handlers.ts +15 -0
- package/examples/10-entities-tools/src/index.ts +31 -0
- package/examples/10-entities-tools/src/schemas.ts +18 -0
- package/examples/10-entities-tools/tests/pulse.harness.ts +40 -0
- package/examples/10-entities-tools/tools-facade.cjs +158 -0
- package/examples/10-entities-tools/tsconfig.json +14 -0
- package/examples/11-events/.pulse/.gitignore +4 -0
- package/examples/11-events/.pulse/config.ts +24 -0
- package/examples/11-events/README.md +194 -0
- package/examples/11-events/package.json +20 -0
- package/examples/11-events/src/index.ts +27 -0
- package/examples/11-events/src/schemas.ts +19 -0
- package/examples/11-events/tests/pulse.harness.ts +34 -0
- package/examples/11-events/tsconfig.json +15 -0
- package/examples/12-mcp-proxy/.pulse/.gitignore +3 -0
- package/examples/12-mcp-proxy/.pulse/config.ts +25 -0
- package/examples/12-mcp-proxy/README.md +149 -0
- package/examples/12-mcp-proxy/package.json +20 -0
- package/examples/12-mcp-proxy/src/index.ts +17 -0
- package/examples/12-mcp-proxy/tests/pulse.harness.ts +29 -0
- package/examples/12-mcp-proxy/tsconfig.json +14 -0
- package/examples/13-jwt-es256/.pulse/config.ts +19 -0
- package/examples/13-jwt-es256/README.md +195 -0
- package/examples/13-jwt-es256/package.json +21 -0
- package/examples/13-jwt-es256/src/index.ts +21 -0
- package/examples/13-jwt-es256/tests/pulse.harness.ts +54 -0
- package/examples/13-jwt-es256/tsconfig.json +14 -0
- package/examples/README.md +36 -0
- package/package.json +66 -6
- package/project-config.schema.json +918 -0
- package/release-manifest.json +427 -0
- package/src/command-spec.js +279 -0
- package/src/completion.js +113 -0
- package/src/diagnostics.js +350 -0
- package/src/documentation.js +45 -0
- package/src/index.d.ts +133 -0
- package/src/index.js +15 -0
- package/src/internal/command-executor.d.ts +29 -0
- package/src/internal/command-executor.js +143 -0
- package/src/internal/command-plan.d.ts +9 -0
- package/src/internal/command-plan.js +73 -0
- package/src/internal/command-reporter.d.ts +15 -0
- package/src/internal/command-reporter.js +133 -0
- package/src/internal/command-request.d.ts +35 -0
- package/src/internal/command-request.js +154 -0
- package/src/internal/node-http.js +54 -0
- package/src/internal/project-context.d.ts +66 -0
- package/src/internal/project-context.js +175 -0
- package/src/project-config-reference.js +4 -0
- package/src/project-config-schema.d.ts +23 -0
- package/src/project-config-schema.js +271 -0
- package/src/project-config.js +724 -0
- package/src/project-execution.js +2930 -0
- package/src/provider-drivers.js +3 -0
- package/src/target-support.js +3 -0
- package/src/typescript-module-loader.js +269 -0
- package/src/workflow.js +78 -0
- package/src/workspace.js +82 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
const path = require('node:path');
|
|
5
|
+
const { runCli } = require('@pulse-compute/wasm-compiler/cli');
|
|
6
|
+
const { getDefaultArtifactsDir } = require('@pulse-compute/wasm-build-support/artifacts-dir');
|
|
7
|
+
const compilerRoot = path.resolve(require.resolve('@pulse-compute/wasm-compiler'), '..', '..');
|
|
8
|
+
const providerProofs = require(path.join(compilerRoot, 'bin', 'provider-proof-composition.js'));
|
|
9
|
+
|
|
10
|
+
runCli(process.argv.slice(2), {
|
|
11
|
+
cwd: process.cwd(),
|
|
12
|
+
stdout: process.stdout,
|
|
13
|
+
stderr: process.stderr,
|
|
14
|
+
defaultOutDir: getDefaultArtifactsDir(process.cwd()),
|
|
15
|
+
providerProofs,
|
|
16
|
+
exitOnComplete: true
|
|
17
|
+
}).then(() => {
|
|
18
|
+
process.exit(process.exitCode || 0);
|
|
19
|
+
}).catch((error) => {
|
|
20
|
+
process.stderr.write(`${error && error.stack ? error.stack : String(error)}\n`);
|
|
21
|
+
process.exit(1);
|
|
22
|
+
});
|
package/cli-spec.json
ADDED
|
@@ -0,0 +1,575 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schemaVersion": "pulse.cli-command-spec.v5",
|
|
3
|
+
"cliVersion": "1.0.0-beta.1",
|
|
4
|
+
"completionShells": [
|
|
5
|
+
"bash",
|
|
6
|
+
"zsh",
|
|
7
|
+
"fish"
|
|
8
|
+
],
|
|
9
|
+
"metaInvocations": [
|
|
10
|
+
{
|
|
11
|
+
"syntax": "pulse --help | pulse -h | pulse help",
|
|
12
|
+
"description": "Print public help."
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"syntax": "pulse --version | pulse -v | pulse version",
|
|
16
|
+
"description": "Print the installed CLI package version."
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"syntax": "pulse completion <bash|zsh|fish>",
|
|
20
|
+
"description": "Print a shell completion script generated from the public command specification."
|
|
21
|
+
}
|
|
22
|
+
],
|
|
23
|
+
"globalOptions": [
|
|
24
|
+
{
|
|
25
|
+
"id": "help",
|
|
26
|
+
"key": "help",
|
|
27
|
+
"flags": [
|
|
28
|
+
{
|
|
29
|
+
"name": "--help"
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
"name": "-h"
|
|
33
|
+
}
|
|
34
|
+
],
|
|
35
|
+
"kind": "boolean",
|
|
36
|
+
"description": "Print public CLI help and exit."
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"id": "json",
|
|
40
|
+
"key": "json",
|
|
41
|
+
"flags": [
|
|
42
|
+
{
|
|
43
|
+
"name": "--json"
|
|
44
|
+
}
|
|
45
|
+
],
|
|
46
|
+
"kind": "boolean",
|
|
47
|
+
"description": "Emit machine-readable JSON. pulse dev emits one JSON event per line."
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"id": "dry-run",
|
|
51
|
+
"key": "dryRun",
|
|
52
|
+
"flags": [
|
|
53
|
+
{
|
|
54
|
+
"name": "--dry-run"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"name": "--plan"
|
|
58
|
+
}
|
|
59
|
+
],
|
|
60
|
+
"kind": "boolean",
|
|
61
|
+
"description": "Resolve and report the command plan without executing it."
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"commands": [
|
|
65
|
+
{
|
|
66
|
+
"name": "init",
|
|
67
|
+
"summary": "Create a conventional .pulse workspace with an async Pulse application and dedicated test harness.",
|
|
68
|
+
"usage": [
|
|
69
|
+
"pulse init [directory] [--name <package-name>] [--force]"
|
|
70
|
+
],
|
|
71
|
+
"positionals": [
|
|
72
|
+
{
|
|
73
|
+
"name": "directory",
|
|
74
|
+
"key": "target",
|
|
75
|
+
"description": "Target directory. Defaults to the current directory."
|
|
76
|
+
}
|
|
77
|
+
],
|
|
78
|
+
"options": [
|
|
79
|
+
{
|
|
80
|
+
"id": "force",
|
|
81
|
+
"key": "force",
|
|
82
|
+
"flags": [
|
|
83
|
+
{
|
|
84
|
+
"name": "--force"
|
|
85
|
+
}
|
|
86
|
+
],
|
|
87
|
+
"kind": "boolean",
|
|
88
|
+
"description": "Allow generated files to replace entries in a non-empty target directory."
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"id": "name",
|
|
92
|
+
"key": "name",
|
|
93
|
+
"flags": [
|
|
94
|
+
{
|
|
95
|
+
"name": "--name"
|
|
96
|
+
}
|
|
97
|
+
],
|
|
98
|
+
"kind": "value",
|
|
99
|
+
"valueName": "<package-name>",
|
|
100
|
+
"description": "Set the generated npm package name."
|
|
101
|
+
}
|
|
102
|
+
],
|
|
103
|
+
"examples": [
|
|
104
|
+
"pulse init ./my-pulse-app",
|
|
105
|
+
"pulse init ./edge-app --name @example/edge-app"
|
|
106
|
+
],
|
|
107
|
+
"diagnostics": [
|
|
108
|
+
"PULSE_INIT_NOT_EMPTY",
|
|
109
|
+
"PULSE_INIT_FILE_EXISTS",
|
|
110
|
+
"PULSE_PROVIDER_UNSUPPORTED"
|
|
111
|
+
],
|
|
112
|
+
"outputs": [
|
|
113
|
+
"Human output lists generated files and next steps.",
|
|
114
|
+
"With --json, emits one initialization result object."
|
|
115
|
+
],
|
|
116
|
+
"sideEffects": [
|
|
117
|
+
"Creates .pulse/config.ts, an async Pulse application, a dedicated test harness, package scripts, and documentation.",
|
|
118
|
+
"Does not install dependencies or run npm, pnpm, or any network operation."
|
|
119
|
+
],
|
|
120
|
+
"exit": "0 on success; 2 for invalid usage, provider selection, or unsafe overwrite conditions."
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"name": "doctor",
|
|
124
|
+
"summary": "Audit project shape, compilation, schemas, provider bindings, output safety, and required tools.",
|
|
125
|
+
"usage": [
|
|
126
|
+
"pulse doctor [directory] [--profile <name>] [--strict]"
|
|
127
|
+
],
|
|
128
|
+
"positionals": [
|
|
129
|
+
{
|
|
130
|
+
"name": "directory",
|
|
131
|
+
"key": "directory",
|
|
132
|
+
"description": "Project discovery start. Defaults to the current directory."
|
|
133
|
+
}
|
|
134
|
+
],
|
|
135
|
+
"options": [
|
|
136
|
+
{
|
|
137
|
+
"id": "strict",
|
|
138
|
+
"key": "strict",
|
|
139
|
+
"flags": [
|
|
140
|
+
{
|
|
141
|
+
"name": "--strict"
|
|
142
|
+
}
|
|
143
|
+
],
|
|
144
|
+
"kind": "boolean",
|
|
145
|
+
"description": "Treat doctor warnings as failed checks."
|
|
146
|
+
},
|
|
147
|
+
{
|
|
148
|
+
"id": "profile",
|
|
149
|
+
"key": "profile",
|
|
150
|
+
"flags": [
|
|
151
|
+
{
|
|
152
|
+
"name": "--profile"
|
|
153
|
+
}
|
|
154
|
+
],
|
|
155
|
+
"kind": "value",
|
|
156
|
+
"valueName": "<profile>",
|
|
157
|
+
"description": "Select a project profile. Precedence: --profile, PULSE_PROFILE, pulse.defaultProfile."
|
|
158
|
+
}
|
|
159
|
+
],
|
|
160
|
+
"examples": [
|
|
161
|
+
"pulse doctor ./my-pulse-app",
|
|
162
|
+
"pulse doctor ./edge-app --strict --json"
|
|
163
|
+
],
|
|
164
|
+
"diagnostics": [
|
|
165
|
+
"PULSE_CONFIG_NOT_FOUND",
|
|
166
|
+
"PULSE_PROJECT_COMPILE_FAILED",
|
|
167
|
+
"PULSE_NODE_VERSION_UNSUPPORTED",
|
|
168
|
+
"PULSE_CANONICAL_NATIVE_COMPILE_FAILED"
|
|
169
|
+
],
|
|
170
|
+
"outputs": [
|
|
171
|
+
"Human output prints every check.",
|
|
172
|
+
"With --json, emits one completed audit object including failed and warning checks."
|
|
173
|
+
],
|
|
174
|
+
"sideEffects": [
|
|
175
|
+
"Reads and compiles the project.",
|
|
176
|
+
"Does not write the build output."
|
|
177
|
+
],
|
|
178
|
+
"exit": "0 when the audit passes; 1 when a completed audit contains failed checks; 2–5 only when the audit command itself cannot be completed."
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
"name": "inspect",
|
|
182
|
+
"summary": "Report canonical compiler, schema, effect, continuation, capability, provider, and build-mode details.",
|
|
183
|
+
"usage": [
|
|
184
|
+
"pulse inspect [directory] [--profile <name>]",
|
|
185
|
+
"pulse inspect --artifact <file.json>"
|
|
186
|
+
],
|
|
187
|
+
"positionals": [
|
|
188
|
+
{
|
|
189
|
+
"name": "directory",
|
|
190
|
+
"key": "directory",
|
|
191
|
+
"description": "Project discovery start. Defaults to the current directory."
|
|
192
|
+
}
|
|
193
|
+
],
|
|
194
|
+
"options": [
|
|
195
|
+
{
|
|
196
|
+
"id": "profile",
|
|
197
|
+
"key": "profile",
|
|
198
|
+
"flags": [
|
|
199
|
+
{
|
|
200
|
+
"name": "--profile"
|
|
201
|
+
}
|
|
202
|
+
],
|
|
203
|
+
"kind": "value",
|
|
204
|
+
"valueName": "<profile>",
|
|
205
|
+
"description": "Select a project profile. Precedence: --profile, PULSE_PROFILE, pulse.defaultProfile."
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
"id": "artifact",
|
|
209
|
+
"key": "artifact",
|
|
210
|
+
"flags": [
|
|
211
|
+
{
|
|
212
|
+
"name": "--artifact"
|
|
213
|
+
}
|
|
214
|
+
],
|
|
215
|
+
"kind": "value",
|
|
216
|
+
"valueName": "<file.json>",
|
|
217
|
+
"description": "Inspect an existing JSON build or compiler artifact instead of a project."
|
|
218
|
+
}
|
|
219
|
+
],
|
|
220
|
+
"examples": [
|
|
221
|
+
"pulse inspect ./my-pulse-app --json",
|
|
222
|
+
"pulse inspect --artifact ./dist/pulse-build.json"
|
|
223
|
+
],
|
|
224
|
+
"diagnostics": [
|
|
225
|
+
"PULSE_CONFIG_NOT_FOUND",
|
|
226
|
+
"PULSE_PROJECT_COMPILE_FAILED",
|
|
227
|
+
"PULSE_CANONICAL_COMPILE_FAILED"
|
|
228
|
+
],
|
|
229
|
+
"outputs": [
|
|
230
|
+
"Human output prints a compact project/compiler summary.",
|
|
231
|
+
"With --json, emits one inspection or artifact object."
|
|
232
|
+
],
|
|
233
|
+
"sideEffects": [
|
|
234
|
+
"Compiles and validates the project in memory.",
|
|
235
|
+
"Does not write the build output."
|
|
236
|
+
],
|
|
237
|
+
"exit": "0 on success; 2–5 according to the emitted stable diagnostic."
|
|
238
|
+
},
|
|
239
|
+
{
|
|
240
|
+
"name": "test",
|
|
241
|
+
"summary": "Run configured cases through the selected provider local-conformance runtime.",
|
|
242
|
+
"usage": [
|
|
243
|
+
"pulse test [directory] [--profile <name>] [--case <name>]"
|
|
244
|
+
],
|
|
245
|
+
"positionals": [
|
|
246
|
+
{
|
|
247
|
+
"name": "directory",
|
|
248
|
+
"key": "directory",
|
|
249
|
+
"description": "Project discovery start. Defaults to the current directory."
|
|
250
|
+
}
|
|
251
|
+
],
|
|
252
|
+
"options": [
|
|
253
|
+
{
|
|
254
|
+
"id": "profile",
|
|
255
|
+
"key": "profile",
|
|
256
|
+
"flags": [
|
|
257
|
+
{
|
|
258
|
+
"name": "--profile"
|
|
259
|
+
}
|
|
260
|
+
],
|
|
261
|
+
"kind": "value",
|
|
262
|
+
"valueName": "<profile>",
|
|
263
|
+
"description": "Select a project profile. Precedence: --profile, PULSE_PROFILE, pulse.defaultProfile."
|
|
264
|
+
},
|
|
265
|
+
{
|
|
266
|
+
"id": "case",
|
|
267
|
+
"key": "caseName",
|
|
268
|
+
"flags": [
|
|
269
|
+
{
|
|
270
|
+
"name": "--case"
|
|
271
|
+
}
|
|
272
|
+
],
|
|
273
|
+
"kind": "value",
|
|
274
|
+
"valueName": "<name>",
|
|
275
|
+
"description": "Run one named project test case."
|
|
276
|
+
}
|
|
277
|
+
],
|
|
278
|
+
"examples": [
|
|
279
|
+
"pulse test ./my-pulse-app",
|
|
280
|
+
"pulse test ./my-pulse-app --case smoke --json"
|
|
281
|
+
],
|
|
282
|
+
"diagnostics": [
|
|
283
|
+
"PULSE_TEST_PROVIDER_REQUIRED",
|
|
284
|
+
"PULSE_PROVIDER_CAPABILITY_MISSING",
|
|
285
|
+
"PULSE_SCHEMA_DECODE"
|
|
286
|
+
],
|
|
287
|
+
"outputs": [
|
|
288
|
+
"Human output uses TAP-like case lines and a summary.",
|
|
289
|
+
"With --json, emits one test-run object; expected stable errors remain inside their case results."
|
|
290
|
+
],
|
|
291
|
+
"sideEffects": [
|
|
292
|
+
"Compiles the project and executes configured deterministic or live fixtures.",
|
|
293
|
+
"Does not write the build output."
|
|
294
|
+
],
|
|
295
|
+
"exit": "0 when all selected cases pass; 1 when the completed test run has failed cases; 2–5 when setup, compilation, runtime, or toolchain execution fails before a normal result."
|
|
296
|
+
},
|
|
297
|
+
{
|
|
298
|
+
"name": "dev",
|
|
299
|
+
"summary": "Start the foreground local server with the selected provider conformance runtime.",
|
|
300
|
+
"usage": [
|
|
301
|
+
"pulse dev [directory] [--profile <name>] [--host <host>] [--port <port>] [--watch|--no-watch] [--once]"
|
|
302
|
+
],
|
|
303
|
+
"positionals": [
|
|
304
|
+
{
|
|
305
|
+
"name": "directory",
|
|
306
|
+
"key": "directory",
|
|
307
|
+
"description": "Project discovery start. Defaults to the current directory."
|
|
308
|
+
}
|
|
309
|
+
],
|
|
310
|
+
"options": [
|
|
311
|
+
{
|
|
312
|
+
"id": "once",
|
|
313
|
+
"key": "once",
|
|
314
|
+
"flags": [
|
|
315
|
+
{
|
|
316
|
+
"name": "--once"
|
|
317
|
+
}
|
|
318
|
+
],
|
|
319
|
+
"kind": "boolean",
|
|
320
|
+
"description": "Close the development server after the first completed request."
|
|
321
|
+
},
|
|
322
|
+
{
|
|
323
|
+
"id": "watch",
|
|
324
|
+
"key": "watch",
|
|
325
|
+
"flags": [
|
|
326
|
+
{
|
|
327
|
+
"name": "--watch",
|
|
328
|
+
"value": true
|
|
329
|
+
},
|
|
330
|
+
{
|
|
331
|
+
"name": "--no-watch",
|
|
332
|
+
"value": false
|
|
333
|
+
}
|
|
334
|
+
],
|
|
335
|
+
"kind": "boolean-value",
|
|
336
|
+
"description": "Enable or disable entry and schema dependency watching. Watching is enabled by default."
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
"id": "profile",
|
|
340
|
+
"key": "profile",
|
|
341
|
+
"flags": [
|
|
342
|
+
{
|
|
343
|
+
"name": "--profile"
|
|
344
|
+
}
|
|
345
|
+
],
|
|
346
|
+
"kind": "value",
|
|
347
|
+
"valueName": "<profile>",
|
|
348
|
+
"description": "Select a project profile. Precedence: --profile, PULSE_PROFILE, pulse.defaultProfile."
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
"id": "host",
|
|
352
|
+
"key": "host",
|
|
353
|
+
"flags": [
|
|
354
|
+
{
|
|
355
|
+
"name": "--host"
|
|
356
|
+
}
|
|
357
|
+
],
|
|
358
|
+
"kind": "value",
|
|
359
|
+
"valueName": "<host>",
|
|
360
|
+
"description": "Override the development listen host."
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
"id": "port",
|
|
364
|
+
"key": "port",
|
|
365
|
+
"flags": [
|
|
366
|
+
{
|
|
367
|
+
"name": "--port"
|
|
368
|
+
}
|
|
369
|
+
],
|
|
370
|
+
"kind": "value",
|
|
371
|
+
"valueName": "<port>",
|
|
372
|
+
"description": "Override the development listen port. Use 0 to request an ephemeral port."
|
|
373
|
+
}
|
|
374
|
+
],
|
|
375
|
+
"examples": [
|
|
376
|
+
"pulse dev ./my-pulse-app",
|
|
377
|
+
"pulse dev ./my-pulse-app --port 0 --once --json"
|
|
378
|
+
],
|
|
379
|
+
"diagnostics": [
|
|
380
|
+
"PULSE_DEV_PROVIDER_UNSUPPORTED",
|
|
381
|
+
"PULSE_REQUEST_BODY_TOO_LARGE",
|
|
382
|
+
"PULSE_FETCH_NETWORK"
|
|
383
|
+
],
|
|
384
|
+
"outputs": [
|
|
385
|
+
"Human output reports the ready URL and reload or error messages.",
|
|
386
|
+
"With --json, stdout is newline-delimited JSON events: compiled, ready, reloaded, request, compile-error, and request-error. It is not one enclosing JSON document."
|
|
387
|
+
],
|
|
388
|
+
"sideEffects": [
|
|
389
|
+
"Binds a foreground HTTP listener.",
|
|
390
|
+
"Watches the entry and schema dependency graph by default.",
|
|
391
|
+
"Configuration-file changes require restarting the command."
|
|
392
|
+
],
|
|
393
|
+
"exit": "0 after a normal server close; 2–5 when setup, compilation, provider, runtime, or toolchain initialization fails."
|
|
394
|
+
},
|
|
395
|
+
{
|
|
396
|
+
"name": "compile",
|
|
397
|
+
"summary": "Compile the canonical project into provider-neutral Pulse-owned WebAssembly.",
|
|
398
|
+
"usage": [
|
|
399
|
+
"pulse compile [directory] [--profile <name>] [--out <dir>] [--clean|--no-clean] [--experimental-native-size]"
|
|
400
|
+
],
|
|
401
|
+
"positionals": [
|
|
402
|
+
{
|
|
403
|
+
"name": "directory",
|
|
404
|
+
"key": "directory",
|
|
405
|
+
"description": "Project discovery start. Defaults to the current directory."
|
|
406
|
+
}
|
|
407
|
+
],
|
|
408
|
+
"options": [
|
|
409
|
+
{
|
|
410
|
+
"id": "clean",
|
|
411
|
+
"key": "clean",
|
|
412
|
+
"flags": [
|
|
413
|
+
{
|
|
414
|
+
"name": "--clean",
|
|
415
|
+
"value": true
|
|
416
|
+
},
|
|
417
|
+
{
|
|
418
|
+
"name": "--no-clean",
|
|
419
|
+
"value": false
|
|
420
|
+
}
|
|
421
|
+
],
|
|
422
|
+
"kind": "boolean-value",
|
|
423
|
+
"description": "Remove or preserve the selected output directory before writing artifacts. Cleaning is enabled by default."
|
|
424
|
+
},
|
|
425
|
+
{
|
|
426
|
+
"id": "experimental-native-size",
|
|
427
|
+
"key": "experimentalNativeSize",
|
|
428
|
+
"flags": [
|
|
429
|
+
{
|
|
430
|
+
"name": "--experimental-native-size"
|
|
431
|
+
}
|
|
432
|
+
],
|
|
433
|
+
"kind": "boolean",
|
|
434
|
+
"description": "Experimentally optimize Native Wasm for size. JavaScript build targets reject this flag."
|
|
435
|
+
},
|
|
436
|
+
{
|
|
437
|
+
"id": "profile",
|
|
438
|
+
"key": "profile",
|
|
439
|
+
"flags": [
|
|
440
|
+
{
|
|
441
|
+
"name": "--profile"
|
|
442
|
+
}
|
|
443
|
+
],
|
|
444
|
+
"kind": "value",
|
|
445
|
+
"valueName": "<profile>",
|
|
446
|
+
"description": "Select a project profile. Precedence: --profile, PULSE_PROFILE, pulse.defaultProfile."
|
|
447
|
+
},
|
|
448
|
+
{
|
|
449
|
+
"id": "out",
|
|
450
|
+
"key": "outDir",
|
|
451
|
+
"flags": [
|
|
452
|
+
{
|
|
453
|
+
"name": "--out"
|
|
454
|
+
}
|
|
455
|
+
],
|
|
456
|
+
"kind": "value",
|
|
457
|
+
"valueName": "<dir>",
|
|
458
|
+
"description": "Override the project-relative artifact output directory."
|
|
459
|
+
}
|
|
460
|
+
],
|
|
461
|
+
"examples": [
|
|
462
|
+
"pulse compile ./my-pulse-app",
|
|
463
|
+
"pulse compile ./edge-app --out ./dist --json",
|
|
464
|
+
"pulse compile ./edge-app --experimental-native-size"
|
|
465
|
+
],
|
|
466
|
+
"diagnostics": [
|
|
467
|
+
"PULSE_BUILD_OUT_UNSAFE",
|
|
468
|
+
"PULSE_CANONICAL_NATIVE_PLAN_FAILED",
|
|
469
|
+
"PULSE_CANONICAL_NATIVE_COMPILE_FAILED"
|
|
470
|
+
],
|
|
471
|
+
"outputs": [
|
|
472
|
+
"Writes pulse-compile.json, the canonical program, native plan, generated AssemblyScript, compact Wasm, WAT, and native manifest.",
|
|
473
|
+
"The output is provider-neutral and does not package a deployment provider runtime.",
|
|
474
|
+
"Experimental size builds record the exact non-default Native compiler optimization settings.",
|
|
475
|
+
"With --json, emits one compile result object containing exact artifact paths and native metadata."
|
|
476
|
+
],
|
|
477
|
+
"sideEffects": [
|
|
478
|
+
"Cleans the output directory by default.",
|
|
479
|
+
"Invokes the lockfile-pinned AssemblyScript compiler.",
|
|
480
|
+
"Refuses absolute, parent-traversal, and symbolic-link traversal outside the project root."
|
|
481
|
+
],
|
|
482
|
+
"exit": "0 on success; 2–5 according to the emitted stable diagnostic."
|
|
483
|
+
},
|
|
484
|
+
{
|
|
485
|
+
"name": "build",
|
|
486
|
+
"summary": "Compile the canonical project and realize the deployment provider selected by the active project profile.",
|
|
487
|
+
"usage": [
|
|
488
|
+
"pulse build [directory] [--profile <name>] [--out <dir>] [--clean|--no-clean] [--experimental-native-size]"
|
|
489
|
+
],
|
|
490
|
+
"positionals": [
|
|
491
|
+
{
|
|
492
|
+
"name": "directory",
|
|
493
|
+
"key": "directory",
|
|
494
|
+
"description": "Project discovery start. Defaults to the current directory."
|
|
495
|
+
}
|
|
496
|
+
],
|
|
497
|
+
"options": [
|
|
498
|
+
{
|
|
499
|
+
"id": "clean",
|
|
500
|
+
"key": "clean",
|
|
501
|
+
"flags": [
|
|
502
|
+
{
|
|
503
|
+
"name": "--clean",
|
|
504
|
+
"value": true
|
|
505
|
+
},
|
|
506
|
+
{
|
|
507
|
+
"name": "--no-clean",
|
|
508
|
+
"value": false
|
|
509
|
+
}
|
|
510
|
+
],
|
|
511
|
+
"kind": "boolean-value",
|
|
512
|
+
"description": "Remove or preserve the selected output directory before writing artifacts. Cleaning is enabled by default."
|
|
513
|
+
},
|
|
514
|
+
{
|
|
515
|
+
"id": "experimental-native-size",
|
|
516
|
+
"key": "experimentalNativeSize",
|
|
517
|
+
"flags": [
|
|
518
|
+
{
|
|
519
|
+
"name": "--experimental-native-size"
|
|
520
|
+
}
|
|
521
|
+
],
|
|
522
|
+
"kind": "boolean",
|
|
523
|
+
"description": "Experimentally optimize Native Wasm for size. JavaScript build targets reject this flag."
|
|
524
|
+
},
|
|
525
|
+
{
|
|
526
|
+
"id": "profile",
|
|
527
|
+
"key": "profile",
|
|
528
|
+
"flags": [
|
|
529
|
+
{
|
|
530
|
+
"name": "--profile"
|
|
531
|
+
}
|
|
532
|
+
],
|
|
533
|
+
"kind": "value",
|
|
534
|
+
"valueName": "<profile>",
|
|
535
|
+
"description": "Select a project profile. Precedence: --profile, PULSE_PROFILE, pulse.defaultProfile."
|
|
536
|
+
},
|
|
537
|
+
{
|
|
538
|
+
"id": "out",
|
|
539
|
+
"key": "outDir",
|
|
540
|
+
"flags": [
|
|
541
|
+
{
|
|
542
|
+
"name": "--out"
|
|
543
|
+
}
|
|
544
|
+
],
|
|
545
|
+
"kind": "value",
|
|
546
|
+
"valueName": "<dir>",
|
|
547
|
+
"description": "Override the project-relative artifact output directory."
|
|
548
|
+
}
|
|
549
|
+
],
|
|
550
|
+
"examples": [
|
|
551
|
+
"pulse build ./my-pulse-app",
|
|
552
|
+
"pulse build ./edge-app --out ./dist --json",
|
|
553
|
+
"pulse build ./edge-app --experimental-native-size"
|
|
554
|
+
],
|
|
555
|
+
"diagnostics": [
|
|
556
|
+
"PULSE_BUILD_OUT_UNSAFE",
|
|
557
|
+
"PULSE_BUILD_PROVIDER_REQUIRED",
|
|
558
|
+
"PULSE_EXPERIMENTAL_NATIVE_SIZE_UNSUPPORTED",
|
|
559
|
+
"PULSE_CANONICAL_NATIVE_COMPILE_FAILED"
|
|
560
|
+
],
|
|
561
|
+
"outputs": [
|
|
562
|
+
"Writes pulse-build.json, the provider-neutral native module, and the configured provider realization.",
|
|
563
|
+
"Fastly builds write generated AssemblyScript and direct-host-ABI native Wasm at bin/main.wasm; no JavaScript runtime image is packaged.",
|
|
564
|
+
"Experimental size builds record the exact non-default Native compiler optimization settings in portable, provider, and build metadata.",
|
|
565
|
+
"With --json, emits one build result object containing exact portable and provider artifact paths."
|
|
566
|
+
],
|
|
567
|
+
"sideEffects": [
|
|
568
|
+
"Cleans the output directory by default.",
|
|
569
|
+
"Invokes the native compiler and configured provider realization.",
|
|
570
|
+
"Refuses absolute, parent-traversal, and symbolic-link traversal outside the project root."
|
|
571
|
+
],
|
|
572
|
+
"exit": "0 on success; 2–5 according to the emitted stable diagnostic."
|
|
573
|
+
}
|
|
574
|
+
]
|
|
575
|
+
}
|