McMaster.Extensions.CommandLineUtils 2.3.0-rc.460

Command-line parsing API and utilities for console applications.

Commonly used types:

McMaster.Extensions.CommandLineUtils.CommandLineApplication
McMaster.Extensions.CommandLineUtils.CommandOption
McMaster.Extensions.CommandLineUtils.IConsole
McMaster.Extensions.CommandLineUtils.Prompt
McMaster.Extensions.CommandLineUtils.ArgumentEscaper

A community-maintained fork of Microsoft.Extensions.CommandLineUtils, plus many enhancements.

This is a prerelease version of McMaster.Extensions.CommandLineUtils.
There is a newer version of this package available.
See the version list below for details.
This package has a SemVer 2.0.0 package version.
This package will only be available to download with SemVer 2.0.0 compatible NuGet clients, such as Visual Studio 2017 (version 15.3) and above or NuGet client 4.3.0 and above. Read more
Install-Package McMaster.Extensions.CommandLineUtils -Version 2.3.0-rc.460
dotnet add package McMaster.Extensions.CommandLineUtils --version 2.3.0-rc.460
paket add McMaster.Extensions.CommandLineUtils --version 2.3.0-rc.460
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Release Notes

2.3.0 Release Candidate - no more changes are expected between this release and 2.3.0 unless there is a bad bug.

## Enhancements:

* Support the POSIX convention for cluster multiple options. For example, `-ixd` is treated the same as `-i -x -d`.

* @bjorg: support SingleOrNoValue notation. `--option[:value]`

* New type: `Pager`. Provides a simple interaction model for displaying console output in a pager.

* Display help text using the `less` pager on macOS/Linux.

* Make suggestions when invalid options or commands are used, but there is a valid one that is similar.
 (Thanks to @MadbHatter for doing the initial work on this.)

* Add support for subcommand aliases. Commands can be given multiple names.
 ```c#
 [Command("organization", "org", "o")]
 public class OrgCommand { }
 ```

* Obsolete the constructor of `[Subcommand]` which takes a string.

* Infer subcommand names from the type name
 ```c#
 [Subcommand(typeof(AddCommand))]
 public class Git { }

 public class AddCommand { } // subcommand name = "add"
 ```

* @lvermeulen: Sort subcommands by name in help text. This can be disabled with `DefaultHelpTextGenerator.SortCommandsByName`.

* @jcaillon: Add API for `UnrecognizedCommandParsingException` which includes suggestions for similar options or commands.

* @TheConstructor: add CommandLineApplication.GetValidationResult()

## Bugs fixed:

* Duplicate subcommand names used to cause undefined behavior. Now, attempting to add a duplicate subcommand name or aliases will
 cause the library to throw before the app can execute.

* Fix bug in subcommand name inference. When not specified, the subcommand always matched the entry assembly name.
 In this update, this convention only applies to the parent command.

* Add generic overloads of `.IsRequired()` for `CommandOption<T>` and `CommandArgument<T>`.

* @handcraftedsource: handled nested HelpOptions (fixes #86 - InvalidOperationException when multiple help options were defined)


See more details here: https://github.com/natemcmaster/CommandLineUtils/blob/master/CHANGELOG.md#v230

Version History

Version Downloads Last updated
2.3.2 3,676 2/5/2019
2.3.1 4,963 1/19/2019
2.3.0 14,534 1/1/2019
2.3.0-rc.460 215 12/15/2018
2.3.0-beta 553 12/4/2018
2.3.0-alpha 1,194 10/3/2018
2.2.5 125,322 7/2/2018
2.2.4 26,387 5/25/2018
2.2.3 15,184 5/11/2018
2.2.2 8,042 4/28/2018
2.2.1 7,744 4/11/2018
2.2.0 69,552 3/31/2018
2.2.0-rc 733 3/23/2018
2.2.0-beta 452 3/8/2018
2.2.0-alpha 437 2/20/2018
2.1.1 35,216 12/28/2017
2.1.0 1,458 12/13/2017
2.1.0-rc 406 12/7/2017
2.1.0-beta 1,050 11/22/2017
2.1.0-alpha 299 11/11/2017
2.0.1 4,740 10/13/2017
2.0.0 3,323 9/16/2017