docs icon indicating copy to clipboard operation
docs copied to clipboard

Update syntax.md

Open abhiramch018 opened this issue 2 weeks ago • 0 comments

📝 PR Description

Summary Adds a concise example demonstrating how to define and use a global --verbosity (-v) option with System.CommandLine.

Changes made

  • Added a new “Global options and verbosity” subsection under the Options section.
  • Included sample code showing how to declare a global option using AddGlobalOption.
  • Documented accepted verbosity values and short/long form examples.

Reason for change The syntax overview previously described options but did not explain how to define global options or handle verbosity behavior.
This update adds practical, minimal guidance consistent with .NET CLI design.

Related issue Fixes #49437


Internal previews

📄 File 🔗 Preview link
docs/standard/commandline/syntax.md Syntax overview: Commands, options, and arguments

abhiramch018 avatar Nov 26 '25 09:11 abhiramch018