<github-username>.github.io
README.md
file.
[text](file.md)
..md
pages are automatically converted to html
with the configuration belowgithub.io
Page will be https://<github-username>.github.io
github.com
Page will be https://github.com/<github-username>/<github-username>.github.io
Create a _config.yml
file:
plugins:
- jekyll-relative-links
relative_links:
enabled: true
collections: true
theme: jekyll-theme-primer
cd "$(git rev-parse --show-toplevel)"
mkdir docs
cd docs
vi docs/index.md
cd ..
git add docs/index.md
git commit -m "initial commit" docs/index.md
git push
Configuration of the GIT Repo
Settings
GitHub Pages
and enable GitHub Pageshttps://<github-username>.github.io/repo
<github-username>.github.io
will be ./docs
, you cannot reach files outside the ./docs
directory...
in a file in the ./docs
folder, will not link to the main
directory in the repo, but will link to the main github.io repository which
is <github-username>.github.io
!Change Layout
cd <repo-main-doc-directory>
test -d _layouts || mkdir _layouts
cd _layouts
wget https://raw.githubusercontent.com/pages-themes/primer/master/_layouts/default.html
vi default.html
cd ..
git add _layouts/default.html
git commit -m "got layout file 'default.html' from https://pages-themes.github.io/primer/" _layouts/default.html
default.html
This site hosted on <a href="https://github.com/{{ site.github.repository_nwo }}">GitHub.com</a>