commandlineparser / commandlineparser/commandline

Option to sort commands by verb name

未關閉
#737 1 則留言 1 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
C#
星號
4.8k
分支
478
PR 合併指標
30 天內沒有已合併 PR

描述

Hi,

Is it possible to get option to sort all command by VerbAttribute?
Example: for next commands -
[Verb("pa", HelpText = "Perform action")]
public class PerformActionRequest { }

[Verb("npa", HelpText = "Don't do it")]
public class PreventActionRequest { }

[Verb("a", HelpText = "Action")]
public class ActionRequest { }

parser.ParseArguments(args, typeof(PreventActionRequest ),
typeof(PerformActionRequest ),
typeof(ActionRequest ))

At cmd we'll see all commands sorted by Verb attribute:
a Action
npa Don't do it
p Perform action

貢獻指南

這個儲存庫沒有索引到貢獻指南

研究方向

Start at the parser.ParseArguments entry point and inspect how VerbAttribute values are collected and displayed in command help. Confirm the desired ordering and identify the existing command-listing tests or entry points; done means commands appear sorted by verb name while retaining their help text.

由索引模型根據 Issue 內容生成。

評估

技術堆疊
csharp
領域
cli
Issue 類型
功能
難度
3/5
預估耗時
1-2 天
活躍度
停滯
描述清晰度
基本清楚
新手友好度
32/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。