How to install a compatible version of jekyll-feed

I was trying to have Jekyll work with GitHub pages but at on October 28, 2019, Jekyll 4 does not work with Jekyll 3.8.5. Right now I have this Gemfile:

source "https://rubygems.org"
# Hello! This is where you manage which Jekyll version is used to run.
# When you want to use a different version, change it below, save the
# file and run `bundle install`. Run Jekyll with `bundle exec`, like so:
#
#     bundle exec jekyll serve
#
# This will help ensure the proper Jekyll version is running.
# Happy Jekylling!
# gem "jekyll", "~> 4.0.0"
# gem "jekyll", "~> 3.8.5"
# This is the default theme for new Jekyll sites. You may change this to anything you like.
gem "minima", "~> 2.5"
gem "jekyll-athena"

# Seems this is needed to install a lot of subcommands, see: https://github.com/jekyll/jekyll-compose
gem 'jekyll-compose', group: [:jekyll_plugins]

# If you want to use GitHub Pages, remove the "gem "jekyll"" above and
# uncomment the line below. To upgrade, run `bundle update github-pages`.
# gem "github-pages", group: :jekyll_plugins
# for jekyll 3.8.5
gem "github-pages", "202", group: :jekyll_plugins

# If you have any plugins, put them here!
group :jekyll_plugins do
  gem "jekyll-feed", "~> 0.12"
end

# Windows and JRuby does not include zoneinfo files, so bundle the tzinfo-data gem
# and associated library.
install_if -> { RUBY_PLATFORM =~ %r!mingw|mswin|java! } do
  gem "tzinfo", "~> 1.2"
  gem "tzinfo-data"
end

# Performance-booster for watching directories on Windows
gem "wdm", "~> 0.1.1", :install_if => Gem.win_platform?

when I try to bundle install it with I get the following error:

$ bundle install
Fetching gem metadata from https://rubygems.org/...........
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies...
Bundler could not find compatible versions for gem "jekyll-feed":
  In Gemfile:
    jekyll-feed (~> 0.12)

    github-pages (= 202) was resolved to 202, which depends on
      jekyll-feed (= 0.11.0)

How do I make sure I can install jekyll-feed compatible with my Gemfile so that I can use github pages?


Try this as your Gemfile instead. You may need to run bundle update

source "https://rubygems.org"

gem "github-pages", group: :jekyll_plugins

# If you have any plugins, put them here!
group :jekyll_plugins do
  gem "jekyll-feed"
  gem "jekyll-compose"
end

# Windows and JRuby does not include zoneinfo files, so bundle the tzinfo-data gem
# and associated library.
install_if -> { RUBY_PLATFORM =~ %r!mingw|mswin|java! } do
  gem "tzinfo", "~> 1.2"
  gem "tzinfo-data"
end

# Performance-booster for watching directories on Windows
gem "wdm", "~> 0.1.1", :install_if => Gem.win_platform?

jekyll-feed is loaded as a dependency of the github-pages gem, so requesting a separate incompatible version in the Gemfile will cause a conflict. Also github-pages should not be pinned to a specific version, because Github can update it at anytime.

See the corrected Gemfile that @mmistakes just posted, although I think the gem "jekyll-feed" is superfluous.

see the instructions for github pages and jekyll: https://help.github.com/en/github/working-with-github-pages/creating-a-github-pages-site-with-jekyll#creating-your-site

For what it’s worth Jekyll’s official documentation omits the GitHub Pages version # from the Gemfile too. I guess it’s useful if you want to rollback to an older version.

source "https://rubygems.org"

gem "github-pages", group: :jekyll_plugins

But as @chuckhoupt noted you probably want the latest version.

Hmmm Im confused, what do I need for my github pages to work?

I tried the Gemfile you suggested but my website still doesn’t work o github. At least it now compiles and I can test it locally. But the one online does NOT work.

My repo is this: https://github.com/brando90/brandomiranda/
My failed website: https://brando90.github.io/brandomiranda/

nothing comes up :frowning:

your index.html has layout: home but there is no layout called home for that theme - at least not in the themes repo. So try changing it to use the default layout.

If you go to your sites /404.html - it exists, and it has a layout of default which is one of the themes layouts.

Once you get it working you will need to set the baseurl to your repo name… baseurl: /brandomiranda since it is a project and it will be served as a sub folder.

I think the issue is the theme you’re using. Not sure if it’s GitHub Pages compatible… most theme gems are not unless it’s GitHub or official Jekyll one like minima.

When I cloned your repo and built it locally with bundle exec jekyll build I get these errors, and a blank index.html page. Which is all related to _layouts not being available because of how you installed the 3rd party theme.

Build Warning: Layout 'page' requested in awards.md does not exist.
Build Warning: Layout 'page' requested in dance.md does not exist.
Build Warning: Layout 'page' requested in home.md does not exist.
Build Warning: Layout 'page' requested in improving-your-research-skills.md does not exist.
Build Warning: Layout 'home' requested in index.markdown does not exist.
Build Warning: Layout 'page' requested in miscellaneous-projects.md does not exist.
Build Warning: Layout 'page' requested in publications.md does not exist.
Build Warning: Layout 'page' requested in research.md does not exist.
Build Warning: Layout 'page' requested in science.md does not exist.
Build Warning: Layout 'page' requested in self-improvement.md does not exist.

For reference the jekyll-theme-minimal only has a default and post layout. The pages above are requesting layouts that don’t exist like page and home.

Looks to me you may be trying to use layouts from minima instead.

@mmistakes I am fine using any theme (specially if it is compatible with disquss). I guess I don’t understand what I need to do to get this work.

You need to use layouts that exist in whatever theme you’re using.
I’ve never used jekyll-theme-minimal but I guess you need to change each of the .md files above that are giving warnings for layouts that don’t exist.

You’d change to layout: post in their YAML Front Matter. That will make the error go away and build something… whether that’s what you’re expecting it to build is another thing.

You may be better off using Jekyll’s default theme minima instead since that appears to be what your post and page’s are using for layouts.

if I use minima what else do I need? do I need any specific files?

I’d love to do this! But how do I do it? I don’t know what actions I have to do to “use the default layout”.

edit your index.markdown file - right now it says layout: home try layout: default instead.

I changed it to minima but now it looks the crap! :frowning:

I wonder why Ive tried safari and chrome both look bad :frowning:

Any ideas? How do others see the side? https://brando90.github.io/brandomiranda/

that is because you need to have the baseurl set in your config.yml file - without it your css is not loading cause it is looking at the wrong url.

try baseurl: /brandomiranda (the name of the project/repo)

Something changed, but it still renders horribly. I don’t understand why it renders so badly.

you didn’t do it quite right - you have:

baseurl: "baseurl: /brandomiranda" #

should be

baseurl: /brandomiranda

thats an embarrassing mistake. Sorry deadlines making me make silly mistakes.

However, it still doesn’t work though. Weird that whats supposed to be the simplest theme doesn’t actually work.