Skip to content

fix: register the verbose option once per command - #2895

Open
vivekjm wants to merge 1 commit into
react-native-community:mainfrom
vivekjm:fix/duplicate-verbose
Open

vivekjm wants to merge 1 commit into
react-native-community:mainfrom
vivekjm:fix/duplicate-verbose

Conversation

@vivekjm

@vivekjm vivekjm commented Nov 13, 2026

Copy link
Copy Markdown

Summary

Fixes #2886. The CLI and the Apple commands both registered --verbose, so iOS help listed it twice and Commander 12 could stop CLI startup for unrelated commands such as config.

Keep a command's own --verbose when it defines one. The Apple help describes both effects of the existing flag, which enables verbose logging and bypasses Xcode output formatters.

Test Plan

  • Added CLI help regressions for run-ios and build-ios. Both failed on main and passed with the fix.
  • Ran yarn build, the 298 unit tests, the targeted CLI tests, and lint.
  • Ran config and both iOS help commands with Commander 12.1.0 against a local React Native checkout. Config returned valid JSON and each help page listed --verbose once.

Checklist

  • Updated the option help.
  • Followed the commit message convention.
  • Tested against a local React Native checkout.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

run-ios and build-ios register --verbose twice, and with commander 12 every command fails: Cannot add option '--verbose' to command 'run-ios'

1 participant