github / pages-gem

A simple Ruby Gem to bootstrap dependencies for setting up and maintaining a local Jekyll environment in sync with GitHub Pages
http://pages.github.com
MIT License
1.83k stars 353 forks source link

External styles are being added when no theme is declared in _config.yml #613

Open bryanbraun opened 5 years ago

bryanbraun commented 5 years ago

Before submitting an issue, please be sure to

This issue affects

The GitHub Pages Gem is intended to help users replicate the GitHub Pages build environment locally. If your issue affects both the hosted version and the version previewed locally, you may be better suited reporting seeking support in other forums.

What did you do (e.g., steps to reproduce)

  1. Clone my repo: git clone git@github.com:bryanbraun/bryanbraun.github.io.git
  2. Install dependencies: bundle install
  3. Delete every file ending in .scss (for good measure)
  4. Run jekyll build.
  5. See the generated file in _site/assets/style.css

What did you expect to happen?

No CSS files should be generated.

What happened instead?

A CSS file is generated containing normalize.css and other styles from jekyll-theme-primer. It looks like my site is falling back to using jekyll-theme-primer as its theme, even though I have no themes defined in _config.yml (and I don't want to use any external theme).

Possible workaround: If I set theme: null it seems like the stylesheet doesn't get added. I'm not sure if this is good to rely on, since it isn't documented anywhere.

Additional information

This issue was previously reported in jekyll/jekyll but it appears to be an issue with pages-gem.

simonvanderveldt commented 5 years ago

Just ran into this rogue CSS file as well. Seems like it's OK to disable the them using null since it's explicitly mentioned in the code, see https://github.com/github/pages-gem/blob/e0063bacf2e0fb4739ec80f6846796c1dc10f35c/lib/github-pages/configuration.rb#L104

liligot commented 4 years ago

https://github.com/vito/atom-autocomplete-gocode.git