Skip to content

Commit 1da1be7

Browse files
committed
remove repo_root, add __init__
1 parent 140e068 commit 1da1be7

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

packages/help/docfx_helper.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,9 @@
2121

2222
def build_docfx(
2323
current_dir: Union[str, pathlib.Path],
24-
repo_root: Union[str, pathlib.Path],
2524
docs_map: Dict[str, str],
2625
) -> None:
2726
current_dir = pathlib.Path(current_dir)
28-
repo_root = pathlib.Path(repo_root)
2927
output_dir = current_dir / "docs" / "_build"
3028

3129
if output_dir.exists():
@@ -58,7 +56,7 @@ def build_docfx(
5856
'gfm',
5957
format='rst'
6058
)
61-
(output_dir / target_filename).write_text(output)
59+
(output_dir / target_filename).write_text(output, encoding="utf-8")
6260
else:
6361
print(f"Warning: Source {source_path} not found.")
6462
(output_dir / target_filename).write_text(f"# {title}\n\nContent missing.")
@@ -95,10 +93,9 @@ def build_docfx(
9593
if __name__ == "__main__":
9694
parser = argparse.ArgumentParser(description="Build DocFX documentation.")
9795
parser.add_argument("--current-dir", required=True, help="Current package directory")
98-
parser.add_argument("--repo-root", required=True, help="Repository root directory")
9996
parser.add_argument("--doc", action="append", nargs=2, metavar=("TITLE", "PATH"), help="Add a document title and its source path")
10097

10198
args = parser.parse_args()
10299

103100
docs_map = {title: path for title, path in args.doc} if args.doc else {}
104-
build_docfx(args.current_dir, args.repo_root, docs_map)
101+
build_docfx(args.current_dir, docs_map)

packages/help/help/__init__.py

Whitespace-only changes.

0 commit comments

Comments
 (0)