Skip to content

Commit

Permalink
Add ostruct to Gemfile for Ruby >= v3.4.0
Browse files Browse the repository at this point in the history
I was seeing the following warning when I ran `bundle exec rake lint`
locally with Ruby v3.4.0-rc1:

    ~/.asdf/installs/ruby/3.4.0-rc1/lib/ruby/gems/3.4.0+1/gems/rubocop-0.58.2/lib/rubocop.rb:607:
    warning: ostruct was loaded from the standard library, but will no longer be part of the default gems starting from Ruby 3.5.0.
    You can add ostruct to your Gemfile or gemspec to silence this warning.
  • Loading branch information
floehopper committed Dec 24, 2024
1 parent b212740 commit 2b05e09
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ if RUBY_VERSION >= '3.3.0'
gem 'base64'
end

# Avoid ostruct gem warning about it not being available in Ruby v3.5
if RUBY_VERSION >= '3.4.0'
gem 'ostruct'
end

if RUBY_ENGINE == 'jruby'
# Workaround for https://github.com/jruby/jruby/issues/8488
gem 'jar-dependencies', '~> 0.4.1'
Expand Down

0 comments on commit 2b05e09

Please sign in to comment.