Warm tip: This article is reproduced from stackoverflow.com, please click
github Markdown wiki

How to convert GitHub Wiki into GitHub pages?

发布于 2020-04-16 11:48:36

I want my existing GitHub Wiki to be served as GitHub pages.

I tried copying all the .md files into /docs and setting that as the source for pages - but it breaks all the internal links.

So I see Read the [[documentation]] or [[Help|get help]]. rather than links.

What's the easiest way to host my wiki on GitHub pages?

Questioner
Terence Eden
Viewed
73
Waylan 2016-12-16 22:32

You need to create manual Markdown links to each page.

[[documentation]] and [[Help|get help]] style links are wikilinks and generally only used in wikis. They are not part of the standard Markdown syntax and not supported by Jekyll (which GitHub Pages uses under the hood). Note that GitHub Wiki supports both styles, so you could edit your links before importing if you like.

Either any, you need to edit your links to manually point to the appropriate pages:

Read the [documentation](path/to/documentation/) or [Help](path/to/get_help.html]

Of course, you will need to adjust the above paths to point at the correct location. As an alternative you may be able to use Jekyll permalinks, which could provide a shortcut for you to identify specific pages without specifying a full path.