Skip to content

Commit

Permalink
indent
Browse files Browse the repository at this point in the history
Signed-off-by: Jinzhe Zeng <[email protected]>
  • Loading branch information
njzjz committed Nov 16, 2024
1 parent f4c5c12 commit 1a77262
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions dargs/dargs.py
Original file line number Diff line number Diff line change
Expand Up @@ -952,12 +952,15 @@ def gen_doc_flag(self, path: list[str] | None = None, **kwargs) -> str:
choicedoc = indent("| possible choices: " + ", ".join(l_choice), INDENT)
realdoc = indent(self.doc + "\n", INDENT) if self.doc else None
anchor = make_rst_refid(arg_path) if kwargs.get("make_anchor") else None
abstractdoc = "\n".join(
[
f"* {ll}: {cc.doc}"
for ll, cc in zip(l_choice, self.choice_dict.values())
if cc.doc
]
abstractdoc = indent(
"\n".join(
[
f"* {ll}: {cc.doc}"
for ll, cc in zip(l_choice, self.choice_dict.values())
if cc.doc
]
),
INDENT,
)
allparts = [
anchor,
Expand Down

0 comments on commit 1a77262

Please sign in to comment.