Skip to content

Commit

Permalink
Force UTF-8 file enconding (#41)
Browse files Browse the repository at this point in the history
Fix #40
  • Loading branch information
Lunik committed Aug 11, 2022
1 parent 44cc8e7 commit 4e953a9
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 @@ -28,7 +28,7 @@ def write_html(site_dir, old_path, new_path):
os.makedirs(old_dir_abs)

# Write the HTML redirect file in place of the old file
with open(old_path_abs, 'w') as f:
with open(old_path_abs, 'w', encoding='utf-8') as f:
log.debug("Creating redirect: '%s' -> '%s'",
old_path, new_path)
f.write(textwrap.dedent(
Expand Down

0 comments on commit 4e953a9

Please sign in to comment.