Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

github link to wiki page from README

Tags:

github

How do I create a link from a README.md file to a Wiki page in github? Every example seems to show linking from one wiki page to another wiki page, or from one README file to another file in the repository. But none that show linking from one to the other

like image 782
veilig Avatar asked May 21 '14 16:05

veilig


People also ask

How do I link a wiki page to GitHub?

You can create links in wikis using the standard markup supported by your page, or using MediaWiki syntax. For example: If your pages are rendered with Markdown, the link syntax is [Link Text](full-URL-of-wiki-page) . With MediaWiki syntax, the link syntax is [[Link Text|nameofwikipage]] .

How do I add a hyperlink in GitHub README?

Links. You can create an inline link by wrapping link text in brackets [ ] , and then wrapping the URL in parentheses ( ) . You can also use the keyboard shortcut Command + K to create a link.

How do I pull wiki from GitHub?

The Wiki pages are managed as a repository. So click on your repository, then on the left side click on Wiki. Finally on the upper right corner click on Clone Repository. There you will clear instructions on how to clone it correctly.

How do you hyperlink in README?

To link inline, type the text you want to link within brackets, "[x]", followed directly by the link URL parentheses, "(y)".


2 Answers

I just came across this question and saw that this was impossible, but stubbornly kept trying anyway. Good news, because this actually can be done with relative links!

If you look at the documentation for relative links on GitHub, you can see that it supports ./ and ../ operands.

Given that your README is located at:

https://github.com/<user-name>/<repo-name>/blob/master/README.md

... and the wiki is located at:

https://github.com/<user-name>/<repo-name>/wiki

... that means you can just crawl back from the README to the wiki, like so:

[My Awesome Wiki](../../wiki)


Update: As some people have pointed out in the comments (thanks!), please be aware that these relative links will break on clones and forks, so be sure to weigh that into your decision!

like image 200
jmar777 Avatar answered Oct 06 '22 07:10

jmar777


You would have to use an absolute URL as opposed to a relative one.

For example:

[Sites Using React](https://github.com/facebook/react/wiki/Sites-Using-React) 
like image 28
maxdeviant Avatar answered Oct 06 '22 06:10

maxdeviant