Skip to content

Exploring ways of using System.CommandLine to build CLI tools

Notifications You must be signed in to change notification settings

aimenux/SystemCommandLineDemo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

.NET

SystemCommandLineDemo

Exploring ways of using System.CommandLine to build CLI tools

In this repo, i m exploring various ways in order to build a simple cli tool based on System.CommandLine.

1️⃣ straightforward way

  • pros : simplicity
  • cons : verbosity

2️⃣ fluent way

  • pros : discoverability
  • cons : encapsulation

3️⃣ poco way

  • pros : encapsulation
  • cons : performance (use of reflection)

To run code in debug or release mode, type the following commands in your favorite terminal :

  • .\Way.exe Upper [InputText]
  • .\Way.exe Lower [InputText]

Tools : vs22, net 6.0, command-line

About

Exploring ways of using System.CommandLine to build CLI tools

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages