MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / windowsFixtureCommand

Function windowsFixtureCommand

e2e/cli/custom-tools-packed.test.ts:88–108  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

86 : `/tmp/apps-packed-fixture-${slug}`;
87
88const windowsFixtureCommand = (path: string): string => `
89$ErrorActionPreference = 'Stop'
90Remove-Item -Recurse -Force '${path}' -ErrorAction SilentlyContinue
91New-Item -ItemType Directory -Force -Path '${path}/tools' | Out-Null
92Set-Content -NoNewline -Encoding UTF8 -Path '${path}/tools/greet.ts' -Value @'
93${"import"} { z } from "zod";
94${"import"} { defineTool } from "executor:app";
95
96const Input = z.object({ name: z.string() });
97
98export default defineTool({
99 description: "Greet",
100 input: Input,
101 async handler(input) {
102 return { greeting: "hello " + input.name };
103 },
104});
105'@
106Set-Content -NoNewline -Encoding UTF8 -Path '${path}/package.json' -Value '{"name":"packed-apps-smoke","dependencies":{"zod":"4.3.6"}}'
107Set-Content -NoNewline -Encoding UTF8 -Path '${path}/bun.lock' -Value ''
108`;
109
110const unixFixtureCommand = (path: string): string => `
111set -eu

Callers 1

writeFixtureFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected