Skip to content

Commit

Permalink
Allow build mkdocs outside root
Browse files Browse the repository at this point in the history
Currently we are expecting that all mkdocs projects have their docs in
their root, but we generate the artifacts relative to their yaml file,
we do the same for sphinx.

Fix readthedocs#5532 (comment)
  • Loading branch information
stsewd committed Mar 26, 2019
1 parent 44951fb commit 88f1ccc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions readthedocs/doc_builder/backends/mkdocs.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,12 @@ class BaseMkdocs(BaseBuilder):

def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.yaml_file = self.get_yaml_config()
self.old_artifact_path = os.path.join(
self.version.project.checkout_path(self.version.slug),
os.path.dirname(self.yaml_file),
self.build_dir,
)
self.root_path = self.version.project.checkout_path(self.version.slug)
self.yaml_file = self.get_yaml_config()

# README: historically, the default theme was ``readthedocs`` but in
# https://github.com/rtfd/readthedocs.org/pull/4556 we change it to
Expand Down

0 comments on commit 88f1ccc

Please sign in to comment.