I’m having an issue described in application/octet-stream content-type return when post permalink doesn't end with .html · Issue #4996 · jekyll/jekyll · GitHub (but comments are disabled there)
I’m using GitHub Pages and trying to preserve URLs after migrating my site from Atlassian Confluence (all pages had no extension or trailing slash)
I’ll summarize the issue here:
- I can set
permalink: /path/Page+Title
in front matter, and then Jekyll will allow the url without .html (it generates a file with .html extension that can be accessed without it) This is good - If the permalink URL has dots in it, eg
/path/Release1.2.3
, then the generated file does not have a .html extension, and is served withContent-Type: application/octet-stream
This is bad - If I add a trailing slash to the permalink on pages with dots, then:
- A directory structure is generated:
Release1.2.3/index.html
- The URL redirects to add a trailing slash This is slightly bad, but tolerable
- All relative links break:
[....](Sibling_Page)
is nowRelease1.2.3/Sibling_Page
This is bad
- A directory structure is generated:
Is there a better approach that does not mess up link URLs in every page with dots in the name? Is there a way to convince Jekyll to generate a .html
page for markdown files with dots?
This issue discusses using a custom converter, but it’s unclear whether this would work with GitHub Pages.
Versions: GitHub supported versions (Jekyll 3.9.0, Minima theme 2.5.1)
Thanks!