Help needed with github pages and hugo: it should work but it doesn't. The theme seems broken


It seems “the site is note able to read” CSS. Or something in the theme is broken.
Here is the source
And here is the
I don’t know what am I doing wrong.

Thank you everybody in advance for the support.

It has to do with your URL paths. Either change the baseurl in your config.toml to baseurl = "" (note the trailing slash), or change the lines in your header.html partial such as href="{{ .Site.BaseURL }}css/highlightjs/monokai.css"> to include a slash between {{ .Site.BaseURL }} and the rest of the path: href="{{ .Site.BaseURL }}/css/highlightjs/monokai.css">.


The basurl was already baseurl = ""

First I changed in the header.html modifing href="{{ .Site.BaseURL }}css/highlightjs/monokai.css"> to href="{{ .Site.BaseURL }}/css/highlightjs/monokai.css">
The I added the slash in all the href inside the header.html file. For example I modified also href="{{ .Site.BaseURL }}apple-touch-icon.png" /> to href="{{ .Site.BaseURL }}/apple-touch-icon.png" />.
It seem that nothing changed.

I forked your source repo. The changes need to be made to your source repo. The baseurl in your config file currently is

baseurl = ""

but it needs to be

baseurl = ""

I’ve confirmed that this fixes your issue.

1 Like