Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes https://github.com/mkdocs/mkdocs/issues/728 #730

Merged
merged 1 commit into from Mar 3, 2016

Conversation

justinkinney
Copy link

Just a possible solution.

@@ -431,7 +435,10 @@ def nest_paths(paths):

branch = nested
for part in parts:
part = filename_to_title(part)
dir = False
if os.path.basename(part) != path:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this line read:

if os.path.basename(path) != part

@justinkinney
Copy link
Author

Ok, based on previous comments, I've added a dirname_to_title() method to handle the code path in nest_paths(). I also simplified my changes since I realized that nest_paths() is only working on paths not filenames due to directory, _ = os.path.split(path).

d0ugal added a commit that referenced this pull request Mar 3, 2016
@d0ugal d0ugal merged commit 0bf0098 into mkdocs:master Mar 3, 2016
@d0ugal
Copy link
Member

d0ugal commented Mar 3, 2016

Works great, thanks! Sorry for the long delay.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants