pages-themes / primer

Primer is a Jekyll theme for GitHub Pages

Home Page:https://pages-themes.github.io/primer/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

When built on github pages, site.theme is `primer`, not `jekyll-theme-primer`, so sass import breaks

deargle opened this issue · comments

The instructions say that /assets/css/style.scss should start with the following:

---
---

@import "{{ site.theme }}";

This build fine locally. However, this leads to the following error on a github pages build:

Your site is having problems building: Your SCSS file assets/css/style.scss has an error on line 1: File to import not found or unreadable: primer. Load path: /tmp/jekyll-remote-theme-20210722-6-at4n5p/_sass. For more information, see https://docs.github.com/github/working-with-github-pages/troubleshooting-jekyll-build-errors-for-github-pages-sites#invalid-sass-or-scss.

It works when I hard-code the sass to say:

---
---
@import "jekyll-theme-primer";

+1 to a fix for this as we have a lot more repos that will need workarounds. Was working ok till quite recently.

While working on this I noticed that the README mentions remote_theme: pages-themes/primer@v0.2.0 which then gives:

... 404 - Not Found - Loading URL: https://codeload.github.com/pages-themes/primer/zip/v0.2.0 (Jekyll::RemoteTheme::DownloadError)

It looks like it should be v0.6.0?

This has been fixed! There are both primer and jekyll-theme-primer scss files.