8
votes

I forked the Solid-jekyll theme (solid-jekyll) and got it to work locally. However, when I pushed it up to Github pages, it seems to loose it's css formatting.

My fork of solid-jekyll is on github, username:BeenzSyed. I tried changing the baseurl to "/solid-jekyll" but that didn't work either.

This is what it looks like on my fork: https://beenzsyed.github.io/solid-jekyll/.

This is what it should like though: http://ojs.xyz/solid-jekyll/.

I think it's because it can't find the _includes/css/style.css file but I'm not sure what to do to fix that. Any help is appreciated!

3
The stylesheets look completely different. beenzsyed.github.io/solid-jekyll/assets/css/style.css starts with normalize. There is no normalize in ojs.xyz/solid-jekyll/assets/css/style.cssMichael Coker
Right - I don’t know how or where my fork is picking up that stylesheet from. Both repo’s stylesheet's point to assets/css/style.css which goes to _layouts/style.css and then to _includes/css/style.css.Beenz

3 Answers

6
votes

Faced exactly same issue long back and it consumed 2-3 days. Find your main stylesheets (like main.css) and save it to assets folder and commit. This way Github will be copying stylesheet to site built. It usually won't copy :( main.css

3
votes

I followed the suggestion of dracos on this GitHub Issue page and related commit to change /_includes/head.html from:

<link rel="stylesheet" href="{{ site.baseurl }}public/css/poole.css">

to

<link rel="stylesheet" href="{{ "/public/css/poole.css" | relative_url }}">

Changing most site.baseurl references to relative_url works in both local testing and on GitHub Pages.

My commit for changes to my site can be found below: https://github.com/naamancampbell/naamancampbell.github.io/commit/f60da4d4e48447708c2e157ff1e07303d5377587

0
votes

As someone pointed out, the live demo uses a different stylesheet. So the repo isn't the same. I suggest creating a new issue in the repository.