Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Set-up blog on Github pages

I have a Github pages site already up and running at http://pshrishi.github.io, where I have my resume posted at pshrishi.github.io/resume and a couple of other presentations at similar URLs/addresses like pshrishi.github.io/XYZ. I would like to host a blog at a URL like pshrishi.github.io/blog.

I have jekyll set-up on my MBP, and have been looking for a step-by step guide to go ahead with the blog. Any help would be appreciated, since I'd like the blog to go live as soon as possible.

I've listed the steps that I've tried so far, below:

  • cd pshrishi.github.io
  • Create a new jekyll project : jekyll new blog
  • Update the _config.yml file.
  • cd blog, and jekyll serve
  • The blog works just fine when I access it on my localhost at localhost:4000
like image 749
Czarconius Avatar asked Dec 11 '25 10:12

Czarconius


1 Answers

Your jekyll is not at the top level of the repo. Github is not able to read it.

Simply move your jekyll out from /blog onto the root directory of this repo.

Added:

Your current wrong setup is like the following:

/pshrishi.github.io
      /blog
          /<jekyll-content> 
          /index.html
          /_posts
          /_config.yml
          /blah-blah
      /resume
          /<jekyll-content-again> 
          /index.html
          /_posts
          /_config.yml
          /blah-blah

You should make the jekyll this way:

/pshrishi.github.io
    /<jekyll-content> 
    /index.html
    /_posts
    /_config.yml
    /blah-blah

Hope this helps :)

like image 80
ytbryan Avatar answered Dec 13 '25 01:12

ytbryan