Improve rendering of :option: in cli docs
This commit is contained in:
parent
aa3be0535f
commit
4e58062025
@ -96,7 +96,9 @@ def opt(text: str) -> str:
|
||||
|
||||
|
||||
def option(x: str) -> str:
|
||||
idx = x.find('-')
|
||||
idx = x.rfind('--')
|
||||
if idx < 0:
|
||||
idx = x.find('-')
|
||||
if idx > -1:
|
||||
x = x[idx:]
|
||||
parts = map(bold, x.split())
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user