Skip to content

armgit / eve

Public Imported from GitHub
0

The Open Framework for Building Agents

fix(setup): link Vercel project non-interactively in the dev TUI (#39)

Rui29e27b8923e5
diff --git a/.changeset/vercel-link-non-interactive.md b/.changeset/vercel-link-non-interactive.md
new file mode 100644
index 000000000..ef10c0849
--- /dev/null
+++ b/.changeset/vercel-link-non-interactive.md
@@ -0,0 +1,5 @@
+---
+"eve": patch
+---
+
+Run `vercel link` non-interactively when connecting a project via the dev TUI `/model` menu (and `eve link`). The link is already fully specified by the team and project picked in the TUI, so the CLI no longer inherits a TTY and can no longer surface its interactive prompts (such as the agent/MCP setup question), which previously corrupted the TUI.
diff --git a/packages/eve/src/setup/vercel-project.test.ts b/packages/eve/src/setup/vercel-project.test.ts
index ceb9b6383..e48c17cbe 100644
--- a/packages/eve/src/setup/vercel-project.test.ts
+++ b/packages/eve/src/setup/vercel-project.test.ts
@@ -455,7 +455,7 @@ describe("linkProject", () => {
expect(mockedRunVercel).toHaveBeenNthCalledWith(
1,
["link", "--project", "prj_new", "--scope", "team-a", "--yes"],
- { cwd: "/tmp/eve-agent", onOutput: expect.any(Function) },
+ { cwd: "/tmp/eve-agent", onOutput: expect.any(Function), nonInteractive: true },
);
});
});
diff --git a/packages/eve/src/setup/vercel-project.ts b/packages/eve/src/setup/vercel-project.ts
index 32addd879..df16f3679 100644
--- a/packages/eve/src/setup/vercel-project.ts
+++ b/packages/eve/src/setup/vercel-project.ts
@@ -624,6 +624,14 @@ export async function linkProject(
runVercel(["link", "--project", project.id, ...scope, "--yes"], {
cwd: projectRoot,
onOutput,
+ // The plan already names the team and project, so the link needs no
+ // input. eve strips the coding-agent env markers (so the CLI does not
+ // mis-react to the agent driving it), which also stops the CLI from
+ // auto-enabling its agent non-interactive default — left with an
+ // inherited TTY it would prompt (e.g. the MCP/plugin setup question)
+ // and read stdin, wedging the dev TUI. Force non-interactive: it both
+ // passes `--non-interactive` and closes the child's stdin.
+ nonInteractive: true,
signal: options.signal,
}),
);