Skip to content

feat: add -y flag to allow for skipping warning message & prompt#2993

Open
reesericci wants to merge 4 commits into
npmx-dev:mainfrom
reesericci:patch-1
Open

feat: add -y flag to allow for skipping warning message & prompt#2993
reesericci wants to merge 4 commits into
npmx-dev:mainfrom
reesericci:patch-1

Conversation

@reesericci

Copy link
Copy Markdown

🔗 Linked issue

🧭 Context

There's currently no way to run the connector non-interactively.

📚 Description

This PR adds a -y flag which skips the prompt.

@vercel

vercel Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
npmx.dev Ready Ready Preview, Comment Jul 4, 2026 5:31am
2 Skipped Deployments
Project Deployment Actions Updated (UTC)
docs.npmx.dev Ignored Ignored Preview Jul 4, 2026 5:31am
npmx-lunaria Ignored Ignored Jul 4, 2026 5:31am

Request Review

@github-actions

github-actions Bot commented Jul 3, 2026

Copy link
Copy Markdown

Hello! Thank you for opening your first PR to npmx, @reesericci! 🚀

Here’s what will happen next:

  1. Our GitHub bots will run to check your changes.
    If they spot any issues you will see some error messages on this PR.
    Don’t hesitate to ask any questions if you’re not sure what these mean!

  2. In a few minutes, you’ll be able to see a preview of your changes on Vercel

  3. One or more of our maintainers will take a look and may ask you to make changes.
    We try to be responsive, but don’t worry if this takes a few days.

@coderabbitai

coderabbitai Bot commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Adds a -y/--yes boolean CLI flag that skips the connector setup warning and confirmation prompt, while keeping the existing cancellation message and zero-exit path when the prompt is shown and declined.

Changes

CLI confirmation skip flag

Layer / File(s) Summary
Add --yes argument and gate confirmation prompt
cli/src/cli.ts
Adds a new yes boolean CLI argument (default false) with -y as an alias, and wraps the warning/confirm prompt so it only runs when args.yes is not set, keeping the cancellation log and exit behaviour when declined.
🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly describes the main change: adding a -y flag to skip the warning and prompt.
Description check ✅ Passed The description is related to the change and correctly states that the -y flag skips the prompt.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Jul 3, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@cli/src/cli.ts`:
- Around line 46-50: The boolean CLI option currently only defines the long form
and does not expose a usable short flag, so `-y` will not set `args.y`. Update
the option in `cli/src/cli.ts` within the CLI argument definition to add the
short-flag alias (or rename the option to `yes` and alias `y`) so the
non-interactive prompt bypass works consistently. Keep the change localized to
the argument configuration that defines `y`.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: c5bb6442-9243-402e-aeda-50b84181dbfe

📥 Commits

Reviewing files that changed from the base of the PR and between 284e9f7 and e8a99ae.

📒 Files selected for processing (1)
  • cli/src/cli.ts

Comment thread cli/src/cli.ts Outdated
@reesericci reesericci changed the title Add -y flag to allow for skipping warning message & prompt feat: add -y flag to allow for skipping warning message & prompt Jul 4, 2026
@ghostdevv ghostdevv added the needs discussion An idea that needs more discussion to understand the scope and impact. label Jul 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs discussion An idea that needs more discussion to understand the scope and impact.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants