@simonagradinaru good news! I had some time to look into your problem.
The styling wasn’t being applied on the posts but it was there on the homepage so I checked the Network tab in developer tools and sure enough the homepage was pulling in
main.css but the posts weren’t. That’s what led me to believe it was your build process.
It seems that in your
.gitignore file you excluded the
public directory. From Hugo’s documentation:
hugo does not remove generated files before building. This means that you should delete your
public/ directory (or the publish directory you specified via flag or configuration file) before running the
hugo command. If you do not remove these files, you run the risk of the wrong files (e.g., drafts or future posts) being left in the generated site.
So I think what happened is that it probably wasn’t being overwritten and netlify kept deploying the old folder? In any event here’s how you can fix it
1.) Delete the public folder from your local machine
public/ to your
3.) Commit the changes to your repo and push it to github
4.) Netlify should automatically trigger the rebuild so just wait.
Even if you build locally, the public folder should now not be uploaded to github. Make sure
public isn’t in the repo! And as proof this all works: https://silly-mirzakhani-f9fd5a.netlify.app/post/2020-09-07-odds-of-finding-love/
I’ll take that down once you’re up and running.