Skip to content

Commit

Permalink
Allow JSON 2.0 on Ruby 2.2 and above
Browse files Browse the repository at this point in the history
  • Loading branch information
jkeiser committed Aug 25, 2016
1 parent 2eff9fb commit 756c1c8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ if Gem::Version.new(RUBY_VERSION) <= Gem::Version.new('1.9.3')
gem 'net-ssh', '~> 2.9'
end

if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('2.2')
gem 'json', '< 2.0'
gem 'rack', '< 2.0'
end

group :test do
gem 'bundler', '~> 1.11'
gem 'minitest', '~> 5.8'
Expand Down
2 changes: 1 addition & 1 deletion train.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
spec.require_paths = ['lib']

spec.add_dependency 'json', '~> 1.8'
spec.add_dependency 'json', '>= 1.8', '< 3.0'
# chef-client < 12.4.1 require mixlib-shellout-2.0.1
spec.add_dependency 'mixlib-shellout', '~> 2.0'
# net-ssh 3.x drops Ruby 1.9 support, so this constraint could be raised when
Expand Down

0 comments on commit 756c1c8

Please sign in to comment.