zerocheck 0.1.0 → 0.1.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 +3 -3
- package/dist/index.js +11 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@ Paste a checklist, review one drafted check and browser verification result per
|
|
|
9
9
|
Requires Node.js 20.19 or newer and a Zerocheck project/account. Create a project in the web app’s Settings, then authorize a device or create a project token.
|
|
10
10
|
|
|
11
11
|
```sh
|
|
12
|
-
npm install --save-dev zerocheck@0.1.
|
|
12
|
+
npm install --save-dev zerocheck@0.1.1
|
|
13
13
|
npx zerocheck login
|
|
14
14
|
npx zerocheck init --project your-project-id --url http://localhost:3000
|
|
15
15
|
npx zerocheck install
|
|
@@ -149,7 +149,7 @@ Use the installed CLI as a stdio MCP server, with an explicit project directory:
|
|
|
149
149
|
"mcpServers": {
|
|
150
150
|
"zerocheck": {
|
|
151
151
|
"command": "npx",
|
|
152
|
-
"args": ["--yes", "zerocheck@0.1.
|
|
152
|
+
"args": ["--yes", "zerocheck@0.1.1", "mcp", "--project-dir", "/absolute/path/to/project"]
|
|
153
153
|
}
|
|
154
154
|
}
|
|
155
155
|
}
|
|
@@ -167,6 +167,6 @@ Local execution sends selected check YAML, the page context needed for AI (inclu
|
|
|
167
167
|
|
|
168
168
|
## Repository development
|
|
169
169
|
|
|
170
|
-
The CLI bundles the shared engine source into `dist/index.js`; it has no unpublished engine-package dependency. From this repository, run `npm run build`, `npm run check`, and `npm test` in `packages/cli`. Tests include a real MCP client communicating with the bundled CLI over stdio. The generated workflow and documentation use version `0.1.
|
|
170
|
+
The CLI bundles the shared engine source into `dist/index.js`; it has no unpublished engine-package dependency. From this repository, run `npm run build`, `npm run check`, and `npm test` in `packages/cli`. Tests include a real MCP client communicating with the bundled CLI over stdio. The generated workflow and documentation use version `0.1.1`; update that pin together with the package version for a release.
|
|
171
171
|
|
|
172
172
|
Hosted runs and imports return a queued handle when browsers are occupied; CLI and MCP keep polling until they finish. The queue holds 20 waiting jobs for up to five minutes and never automatically resumes interrupted jobs after restart. Recent imports is available in the web app’s Checks page.
|
package/dist/index.js
CHANGED
|
@@ -6979,7 +6979,7 @@ async function loginCommand() {
|
|
|
6979
6979
|
let device;
|
|
6980
6980
|
try {
|
|
6981
6981
|
device = await apiRequest("/v1/cli/auth/device", {
|
|
6982
|
-
body: { device_name: deviceName, client_version: "0.1.
|
|
6982
|
+
body: { device_name: deviceName, client_version: "0.1.1" },
|
|
6983
6983
|
authed: false
|
|
6984
6984
|
});
|
|
6985
6985
|
} catch (err) {
|
|
@@ -11194,7 +11194,7 @@ async function doctorCommand(options) {
|
|
|
11194
11194
|
|
|
11195
11195
|
// src/commands/init.ts
|
|
11196
11196
|
import { promises as fs5 } from "fs";
|
|
11197
|
-
import { basename, join as join7, resolve as resolve5 } from "path";
|
|
11197
|
+
import { basename, dirname as dirname4, join as join7, resolve as resolve5 } from "path";
|
|
11198
11198
|
import { createRequire } from "module";
|
|
11199
11199
|
import { spawn } from "child_process";
|
|
11200
11200
|
import { stringify } from "yaml";
|
|
@@ -11244,7 +11244,7 @@ jobs:
|
|
|
11244
11244
|
node-version: '22'
|
|
11245
11245
|
- name: Install Zerocheck
|
|
11246
11246
|
run: |
|
|
11247
|
-
npm install --prefix "$RUNNER_TEMP/zerocheck-cli" --no-save --package-lock=false zerocheck@0.1.
|
|
11247
|
+
npm install --prefix "$RUNNER_TEMP/zerocheck-cli" --no-save --package-lock=false zerocheck@0.1.1
|
|
11248
11248
|
echo "$RUNNER_TEMP/zerocheck-cli/node_modules/.bin" >> "$GITHUB_PATH"
|
|
11249
11249
|
- name: Restore learned targets
|
|
11250
11250
|
uses: actions/cache@v4
|
|
@@ -11318,7 +11318,12 @@ async function initCommand(options) {
|
|
|
11318
11318
|
}
|
|
11319
11319
|
async function installCommand(options) {
|
|
11320
11320
|
const require2 = createRequire(import.meta.url);
|
|
11321
|
-
const
|
|
11321
|
+
const manifestPath = require2.resolve("playwright/package.json");
|
|
11322
|
+
const manifest = JSON.parse(await fs5.readFile(manifestPath, "utf8"));
|
|
11323
|
+
if (typeof manifest.bin?.playwright !== "string" || !manifest.bin.playwright.trim()) {
|
|
11324
|
+
throw new Error("The installed Playwright package does not declare its CLI binary. Reinstall Zerocheck.");
|
|
11325
|
+
}
|
|
11326
|
+
const cli = resolve5(dirname4(manifestPath), manifest.bin.playwright);
|
|
11322
11327
|
await new Promise((resolve8, reject) => {
|
|
11323
11328
|
const child = spawn(process.execPath, [cli, "install", ...options.withDeps ? ["--with-deps"] : [], "chromium"], { stdio: "inherit" });
|
|
11324
11329
|
child.once("error", reject);
|
|
@@ -17272,7 +17277,7 @@ var runner = z2.enum(["local", "hosted"]).default("local").describe("Local brows
|
|
|
17272
17277
|
var output = (value) => ({ content: [{ type: "text", text: JSON.stringify(value) }], structuredContent: { result: value } });
|
|
17273
17278
|
var error = (value) => ({ isError: true, content: [{ type: "text", text: JSON.stringify({ error: "operation_failed", message: value instanceof Error ? value.message : String(value) }) }] });
|
|
17274
17279
|
function createMcpServer(services) {
|
|
17275
|
-
const server = new McpServer({ name: "zerocheck", version: "0.1.
|
|
17280
|
+
const server = new McpServer({ name: "zerocheck", version: "0.1.1" });
|
|
17276
17281
|
server.registerTool("list_checks", {
|
|
17277
17282
|
description: "List the repository YAML checks, IDs, exact contents and revisions. Does not execute them.",
|
|
17278
17283
|
inputSchema: { paths: z2.array(z2.string()).optional(), environment },
|
|
@@ -17412,7 +17417,7 @@ async function mcpCommand(options) {
|
|
|
17412
17417
|
}
|
|
17413
17418
|
|
|
17414
17419
|
// src/index.ts
|
|
17415
|
-
var program = new Command().name("zerocheck").version("0.1.
|
|
17420
|
+
var program = new Command().name("zerocheck").version("0.1.1").description("Turn your team\u2019s manual release checklist into repeatable browser tests.");
|
|
17416
17421
|
var directory = (command) => command.option("--project-dir <path>", "Repository project directory", process.cwd());
|
|
17417
17422
|
var environment2 = (command) => directory(command).addOption(new Option("--env <environment>", "Named project environment").choices(["dev", "staging", "production"]));
|
|
17418
17423
|
var execution = (command) => environment2(command).addOption(new Option("--runner <runner>", "Browser execution location").choices(["local", "hosted"]).default("local"));
|