fix(cli): inert --install-service also skips the start prompt

On an interactive terminal the stubbed flag still reached the "Start
Paperclip now?" prompt, so a PTY-driven automation run could hang
waiting for input. Treat an explicit --install-service as an already
decided start at both sites: configure, warn, exit.
This commit is contained in:
Devin Foley committed 2026-08-25 02:02:17 -07:00
1 parent d4894da7eb
commit 45ac13cd7d
1 file changed
+2 -2
+2 -2
View File
@@ -472,7 +472,7 @@ export async function onboard(opts: OnboardOptions): Promise<void> {
// fall through to a blocking foreground start: configure and exit so
// scripted installs fail fast instead of hanging.
let shouldRunNow = !serviceInstalled && opts.installService !== true && (opts.run === true || opts.yes === true);
if (shouldOfferForegroundStart({ serviceInstalled, startAlreadyDecided: shouldRunNow, invokedByRun: opts.invokedByRun === true, interactive: Boolean(process.stdin.isTTY && process.stdout.isTTY) })) {
if (shouldOfferForegroundStart({ serviceInstalled, startAlreadyDecided: shouldRunNow || opts.installService === true, invokedByRun: opts.invokedByRun === true, interactive: Boolean(process.stdin.isTTY && process.stdout.isTTY) })) {
const answer = await p.confirm({
message: "Start Paperclip now?",
initialValue: true,
@@ -750,7 +750,7 @@ export async function onboard(opts: OnboardOptions): Promise<void> {
// fall through to a blocking foreground start: configure and exit so
// scripted installs fail fast instead of hanging.
let shouldRunNow = !serviceInstalled && opts.installService !== true && (opts.run === true || opts.yes === true);
if (shouldOfferForegroundStart({ serviceInstalled, startAlreadyDecided: shouldRunNow, invokedByRun: opts.invokedByRun === true, interactive: Boolean(process.stdin.isTTY && process.stdout.isTTY) })) {
if (shouldOfferForegroundStart({ serviceInstalled, startAlreadyDecided: shouldRunNow || opts.installService === true, invokedByRun: opts.invokedByRun === true, interactive: Boolean(process.stdin.isTTY && process.stdout.isTTY) })) {
const answer = await p.confirm({
message: "Start Paperclip now?",
initialValue: true,