Skip to content

Commit

Permalink
Fix directory depth
Browse files Browse the repository at this point in the history
Signed-off-by: Sara Damiano <[email protected]>
  • Loading branch information
SRGDamia1 committed Aug 13, 2024
1 parent 46570c9 commit 3281928
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
8 changes: 5 additions & 3 deletions docs/documentExamples.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,24 @@
if "GITHUB_WORKSPACE" in os.environ.keys() and "DOC_ROOT" in os.environ.keys():
docbuild_dir = os.environ.get("DOC_ROOT")
repo_name = os.environ.get("GITHUB_REPOSITORY").split("/")[1]
relative_dir = f"../../../../{repo_name}/"
else:
docbuild_dir = os.getcwd()
repo_name = docbuild_dir.replace("\\\\", "/").replace("\\", "/").split("/")[-2]
relative_dir = f"../../{repo_name}/"

# where to write the file
output_file = "../docs/examples.dox"
output_file = relative_dir + "docs/examples.dox"
output_file = os.path.join(docbuild_dir, output_file)
output_file = os.path.abspath(os.path.realpath(output_file))

# The examples directory
examples_dir = "../examples/"
examples_dir = relative_dir + "examples/"
examples_path = os.path.join(docbuild_dir, examples_dir)
examples_path = os.path.abspath(os.path.realpath(examples_path))

# The extras directory
extras_dir = "../extras/"
extras_dir = relative_dir + "extras/"
extras_path = os.path.join(docbuild_dir, extras_dir)
extras_path = os.path.abspath(os.path.realpath(extras_path))

Expand Down
2 changes: 2 additions & 0 deletions docs/fixFunctionsInGroups.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
import xml.etree.ElementTree as ET

# %%
# Some working directories

# The workspace directory
if "GITHUB_WORKSPACE" in os.environ.keys() and "DOC_ROOT" in os.environ.keys():
docbuild_dir = os.environ.get("DOC_ROOT")
Expand Down

0 comments on commit 3281928

Please sign in to comment.