Skip to content

Commit

Permalink
Lock http_parser.rb gem to v0.6.x on JRuby (#8943)
Browse files Browse the repository at this point in the history
since newer versions of the gem do not have a Java counterpart
  • Loading branch information
ashmaroli committed Jan 20, 2022
1 parent 070a4d4 commit 4ea4f14
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Gemfile
Expand Up @@ -37,7 +37,12 @@ group :test do
gem "test-theme-skinny", :path => File.expand_path("test/fixtures/test-theme-skinny", __dir__)
gem "test-theme-symlink", :path => File.expand_path("test/fixtures/test-theme-symlink", __dir__)

gem "jruby-openssl", "0.10.1" if RUBY_ENGINE == "jruby"
# http_parser.rb has stopped shipping jruby-compatible versions
# latest compatible one was 0.6.0 https://rubygems.org/gems/http_parser.rb
if RUBY_ENGINE == "jruby"
gem "http_parser.rb", "~> 0.6.0"
gem "jruby-openssl"
end
end

#
Expand Down
3 changes: 3 additions & 0 deletions lib/jekyll/commands/new.rb
Expand Up @@ -101,6 +101,9 @@ def gemfile_contents
# kramdown v1, comment out this line.
gem "kramdown-parser-gfm"
# Lock `http_parser.rb` gem to `v0.6.x` on JRuby builds since newer versions of the gem
# do not have a Java counterpart.
gem "http_parser.rb", "~> 0.6.0", :platforms => [:jruby]
RUBY
end

Expand Down

0 comments on commit 4ea4f14

Please sign in to comment.