diff --git a/scripts/scenarios/start-app.ts b/scripts/scenarios/start-app.ts index 5dee3f26c1..893601f000 100644 --- a/scripts/scenarios/start-app.ts +++ b/scripts/scenarios/start-app.ts @@ -126,6 +126,11 @@ const startApp = Effect.fn("startApp")(function* (input: { const checkout = yield* HostProcess.WorkingDirectory; const hostEnvironment = yield* HostProcess.Environment; yield* prepareHome(input.home); + const inheritedGit = path.join(input.home, "other-checkout", ".git"); + yield* fs.makeDirectory(path.join(inheritedGit, "objects"), { recursive: true }); + yield* fs.makeDirectory(path.join(inheritedGit, "refs"), { recursive: true }); + yield* fs.writeFileString(path.join(inheritedGit, "HEAD"), "ref: refs/heads/main\n"); + yield* fs.writeFileString(path.join(inheritedGit, "config"), '[core]\n repositoryformatversion = 0\n bare = false\n[remote "upstream"]\n gh-resolved = base\n'); const env = { ...hostEnvironment, PATH: `${path.join(input.home, "bin")}:${hostEnvironment.PATH ?? ""}`, @@ -155,6 +160,9 @@ const startApp = Effect.fn("startApp")(function* (input: { args: devRunner("dev:server", ports), env: { ...webEnv, + GIT_DIR: inheritedGit, + GIT_CONFIG_GLOBAL: "/dev/null", + T3CODE_DEV_SEED: "0", T3CODE_DEV_ALLOWED_ORIGINS: origin, // Makes the startup pairing link reusable, so every test can sign in with it. T3CODE_DEV_AUTH_TOKEN: `${token}${token}`.replaceAll("-", ""),