alecthomas/kong

Xor is ignored with positional arguments

開放

#255 建立於 2021年12月22日

 (5 則留言) (1 個反應) (0 位負責人)Go (183 個分叉)user submission
enhancementhelp wanted

倉庫指標

星標
 (3,160 顆星)
PR 合併指標
 (平均合併 11天 16小時) (30 天內合併 7 個 PR)

描述

I would like to do something like:

run --defaults

or:

run foo bar

but prevent:

run --defaults foo bar

It seems xor for positional arguments (flag with arg:"") does not do anything: there is no error if both are provided.

貢獻者指南