Skip to content

Commit

Permalink
Normalize only capitalized README to index (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
drts01 committed Aug 3, 2022
1 parent b6c501c commit b4d7683
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mkdocs_redirects/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def get_html_path(path, use_directory_urls):
name_orig = posixpath.splitext(filename)[0]

# Both `index.md` and `README.md` files are normalized to `index.html` during build
name = 'index' if name_orig.lower() in ('index', 'readme') else name_orig
name = 'index' if name_orig in ('index', 'README') else name_orig

# Directory URLs require some different logic. This mirrors mkdocs' internal logic.
if use_directory_urls:
Expand Down

0 comments on commit b4d7683

Please sign in to comment.