I recently set up a personal repo on github.io and on on my site, wanted to link a .html document ( https://github.com/cheryltky/covid19/blob/a1934d0b4219a8033a467e9bda90a0ce04e6f028/covid19stats.Rmd) from the covid project repo of mine to my personal repo under the “projects link”. (https://github.com/cheryltky/cheryltky.github.io/blob/2cb6fd614a28cc722ff3ec37dcad76adefd38d6d/projects.Rmd)
Does anyone know how I can do this? I tried the simple [document name](link to document) technique, but it would not open the linked url.
Since the file you want to link to is located in another repository, you’ll have to include that repo’s name as a sub directory in the URL. Example:
- Your GitHub page: https://cheryltky.github.io/
- Your project page’s sub directory: https://cheryltky.github.io/covid19/
- file located in that project’s directory: https://cheryltky.github.io/covid19/covid19stats.html
If you were to create a link with markdown, it’d look like this.
[Covid-19 Global Data Visuals](https://cheryltky.github.io/covid19/covid19stats.html)
or this, which is shorter and more flexible, because if cloned locally it’d refer to the local file and not the online file.
[Covid-19 Global Data Visuals](/covid19/covid19stats.html)