Skip to content

Commit 8400e21

Browse files
committed
Update
1 parent 9209e29 commit 8400e21

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

docs/source/conf.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -81,11 +81,12 @@
8181
# cut to v1.2
8282
# the version varible is used in layout.html: https://github.com/pytorch/executorch/blob/main/docs/source/_templates/layout.html#L29
8383
version = release = "main"
84-
if et_version_docs.startswith("refs/tags/v"):
85-
version = ".".join(
86-
et_version_docs.split("/")[-1].split("-")[0].lstrip("v").split(".")[:2]
87-
)
88-
print(f"Version: {version}")
84+
if et_version_docs:
85+
if et_version_docs.startswith("refs/tags/v"):
86+
version = ".".join(
87+
et_version_docs.split("/")[-1].split("-")[0].lstrip("v").split(".")[:2]
88+
)
89+
print(f"Version: {version}")
8990
html_title = " ".join((project, version, "documentation"))
9091

9192
breathe_projects = {"ExecuTorch": "../build/xml/"}

0 commit comments

Comments
 (0)