| ... | ... | @@ -116,33 +116,9 @@ const makeFakeUvToolchain = Effect.fn("AcpRegistrySupport.test.makeFakeUvToolcha |
| 116 | 116 | const logPath = path.join(rootDirectory, "uv.log"); |
| 117 | 117 | yield* fileSystem.makeDirectory(toolchainBin, { recursive: true }); |
| 118 | 118 | yield* fileSystem.writeFileString(logPath, ""); |
| 119 | | yield* fileSystem.writeFileString( |
| 119 | yield* fileSystem.copyFile( |
| 120 | yield* path.fromFileUrl(new URL("./testing/AcpRegistrySupport.uv.fixture.sh", import.meta.url)), |
| 120 | 121 | uvPath, |
| 121 | | [ |
| 122 | | "#!/bin/sh", |
| 123 | | 'printf \'%s\\n\' "$*" >> "$FAKE_UV_LOG"', |
| 124 | | 'tool_bin="${UV_TOOL_BIN_DIR:-$FAKE_UV_BIN}"', |
| 125 | | 'executable="$tool_bin/fast-agent"', |
| 126 | | 'printf "tool-dir=%s bin-dir=%s\\n" "$UV_TOOL_DIR" "$UV_TOOL_BIN_DIR" >> "$FAKE_UV_LOG"', |
| 127 | | 'if [ "$1" = "tool" ] && [ "$2" = "dir" ] && [ "$3" = "--bin" ]; then', |
| 128 | | " printf '%s\\n' \"$tool_bin\"", |
| 129 | | " exit 0", |
| 130 | | "fi", |
| 131 | | 'if [ "$1" = "tool" ] && [ "$2" = "list" ]; then', |
| 132 | | ' if [ -x "$executable" ]; then', |
| 133 | | " printf 'fast-agent-acp v0.10.1\\n- fast-agent\\n'", |
| 134 | | " fi", |
| 135 | | " exit 0", |
| 136 | | "fi", |
| 137 | | 'if [ "$1" = "tool" ] && [ "$2" = "install" ] && [ "$3" = "--force" ]; then', |
| 138 | | ' mkdir -p "$tool_bin"', |
| 139 | | " printf '#!/bin/sh\\n' > \"$executable\"", |
| 140 | | ' chmod 755 "$executable"', |
| 141 | | " exit 0", |
| 142 | | "fi", |
| 143 | | "exit 64", |
| 144 | | "", |
| 145 | | ].join("\n"), |
| 146 | 122 | ); |
| 147 | 123 | yield* fileSystem.chmod(uvPath, 0o755); |
| 148 | 124 | return { |