Closed peterjc closed 9 years ago
See https://help.github.com/articles/redirects-on-github-pages/
Consider a MediaWiki page like this from http://biopython.org/wiki/Git which redirects to http://biopython.org/wiki/SourceCode
#REDIRECT [[SourceCode]]
The pandoc GitHub Flavour Markdown output results in a place holder page Git.md with a link to the new page.
Git.md
What we seem to need to do instead is to add a redirect_from line to the Jekyll header in SourceCode.md, e.g.
redirect_from
SourceCode.md
--- ... existing meta data like title ... redirect_from: "/wiki/Git" ---
Update: Even easier, we can edit Git.md with the redirect_to tag instead. For instance,
redirect_to
--- title: Git redirect_to: /wiki/SourceCode --- This page should redirect you to [SourceCode](SourceCode "wikilink").
Appears to be working as of https://github.com/peterjc/mediawiki_to_git_md/commit/7144e27dc96b257584a166f5c9ac68452a0f3553
TODO: Use the _config.yml entry baseurl with prefix?
_config.yml
baseurl
See https://help.github.com/articles/redirects-on-github-pages/
Consider a MediaWiki page like this from http://biopython.org/wiki/Git which redirects to http://biopython.org/wiki/SourceCode
The pandoc GitHub Flavour Markdown output results in a place holder page
Git.md
with a link to the new page.What we seem to need to do instead is to add a
redirect_from
line to the Jekyll header inSourceCode.md
, e.g.Update: Even easier, we can edit
Git.md
with theredirect_to
tag instead. For instance,