I'm creating my personal blog (davioooh.com) using Jekyll and hosting it on GitHub pages.
But I recently discovered a strange thing...
When pushed/deployed to my repository, the blog sitemap.xml
includes two extra urls:
<url>
<loc>
http://davioooh.com/assets/javascript/anchor-js/docs/grunticon/preview.html
</loc>
<lastmod>2017-08-11T16:40:49+00:00</lastmod>
</url>
<url>
<loc>
http://davioooh.com/assets/javascript/anchor-js/docs/index.html
</loc>
<lastmod>2017-08-11T16:40:49+00:00</lastmod>
</url>
I can't understand why... I'm not using any anchor-js gem or plug-in...
The only gems declared in my _config.yml
and Gemfile
are:
gems:
- jekyll-feed
- jekyll-seo-tag
- jekyll-paginate
- jekyll-sitemap
So why I'm getthing that urls?
NOTE: the sitemap is correct when I test the site locally on my dev machine.
NOTE: I'm using a custom theme (regular theme, not gem-based). No theme declared in my _config.yml
. Here you find my blog repository: https://github.com/davioooh/davioooh.github.io
UPDATE Tried to replace jekyll
gem with github-pages
in my Gemfile
as suggested by marcanuy. It works locally, but after a new push sitemap still includes the extra urls...
UPDATE Found GitHub pages reference listing default params for Jekyll websites. Default theme is, as expected, jekyll-theme-primer
. How can I override this setting if I'm not using gem-based theme?
It comes from your theme: jekyll-theme-primer
Primer is what powers GitHub's frontend. If you're not using this theme explicitly, it probably comes from GitHub Pages' own usage of the Primer framework
Because you are not using the same dependencies Github Pages uses. To replicate the environment used by Github, you need to use the gem: github-pages
.
As @ashmaroli said, these files comes from jekyll-theme-primer
which is used by Github Pages, if you are using your own theme files, then just make sure there are no theme:
key in your _config.yml
and run bundle update
. Using the right github-pages
gem will fix it and those files won't be included in your final site.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With