diff --git a/packages/cli/package.json b/packages/cli/package.json index 89b9673..308bbdb 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -14,6 +14,10 @@ "bin": { "ocas": "dist/index.js" }, + "files": [ + "dist", + "prompts" + ], "dependencies": { "@ocas/core": "workspace:*", "@ocas/fs": "workspace:*" diff --git a/packages/cli/src/index.ts b/packages/cli/src/index.ts index 6108423..385e32c 100644 --- a/packages/cli/src/index.ts +++ b/packages/cli/src/index.ts @@ -1234,7 +1234,7 @@ switch (cmd) { switch (sub) { case "usage": { const content = readFileSync( - join(__dirname, "prompts", "usage.md"), + join(__dirname, "..", "prompts", "usage.md"), "utf-8", ); process.stdout.write(content); @@ -1242,7 +1242,7 @@ switch (cmd) { } case "setup": { const content = readFileSync( - join(__dirname, "prompts", "setup.md"), + join(__dirname, "..", "prompts", "setup.md"), "utf-8", ); process.stdout.write(content); diff --git a/packages/cli/tests/__snapshots__/edge-cases.test.ts.snap b/packages/cli/tests/__snapshots__/edge-cases.test.ts.snap index 96cb78c..6712568 100644 --- a/packages/cli/tests/__snapshots__/edge-cases.test.ts.snap +++ b/packages/cli/tests/__snapshots__/edge-cases.test.ts.snap @@ -466,5 +466,5 @@ Flags: --epsilon Cutoff threshold for render (default: 0.01) --pipe, -p Read from stdin (put/hash: raw JSON payload; render: { type, value } envelope) -Agent: If you have not installed the ocas skill for this version (0.3.0), run \`ocas prompt setup\` and follow the instructions." +Agent: If you have not installed the ocas skill for this version (0.3.1), run \`ocas prompt setup\` and follow the instructions." `; diff --git a/packages/cli/tests/edge-cases.test.ts b/packages/cli/tests/edge-cases.test.ts index f55fd2e..715fdd3 100644 --- a/packages/cli/tests/edge-cases.test.ts +++ b/packages/cli/tests/edge-cases.test.ts @@ -52,6 +52,7 @@ describe("Phase 7: Edge Cases", () => { { encoding: "utf-8", timeout: 10000, + env: { ...process.env, NODE_NO_WARNINGS: "1" }, }, ); return { stdout: stdout.trim(), stderr: "", exitCode: 0 }; @@ -177,6 +178,7 @@ describe("Phase 3: Variable System", () => { { encoding: "utf-8", timeout: 10000, + env: { ...process.env, NODE_NO_WARNINGS: "1" }, }, ); return { stdout: stdout.trim(), stderr: "", exitCode: 0 }; @@ -379,6 +381,7 @@ describe("Phase 4: Template System", () => { { encoding: "utf-8", timeout: 10000, + env: { ...process.env, NODE_NO_WARNINGS: "1" }, }, ); return { stdout: stdout.trim(), stderr: "", exitCode: 0 }; diff --git a/packages/cli/tests/schema-validation.test.ts b/packages/cli/tests/schema-validation.test.ts index 5325f5e..52a8952 100644 --- a/packages/cli/tests/schema-validation.test.ts +++ b/packages/cli/tests/schema-validation.test.ts @@ -610,6 +610,7 @@ describe("Phase 2: Schema Validation", () => { { encoding: "utf-8", timeout: 10000, + env: { ...process.env, NODE_NO_WARNINGS: "1" }, }, ).trim(); } catch (e: unknown) { @@ -635,6 +636,7 @@ describe("Phase 2: Schema Validation", () => { { encoding: "utf-8", timeout: 10000, + env: { ...process.env, NODE_NO_WARNINGS: "1" }, }, ); } catch (e: unknown) {