From a7ae1a6c3c3b3cd27ce012ac7664a15e6720a4ed Mon Sep 17 00:00:00 2001 From: Matt Brictson Date: Thu, 29 Aug 2019 08:59:45 -0700 Subject: [PATCH] Exclude danger to fix Ruby 2.0.0 CI error (#2030) danger no longer installs cleanly on Ruby 2.0.0. Our CI only runs danger on Ruby 2.5, so there is no reason to install it for older versions. Fixes #2029 --- Gemfile | 5 +++++ capistrano.gemspec | 1 - 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/Gemfile b/Gemfile index 15b485ac..a95a3504 100644 --- a/Gemfile +++ b/Gemfile @@ -30,3 +30,8 @@ end if Gem::Requirement.new("< 2.1").satisfied_by?(Gem::Version.new(RUBY_VERSION)) gem "i18n", "< 1.3.0" end + +# We only run danger once on a new-ish ruby; no need to install it otherwise +if Gem::Requirement.new("> 2.4").satisfied_by?(Gem::Version.new(RUBY_VERSION)) + gem "danger" +end diff --git a/capistrano.gemspec b/capistrano.gemspec index b98a9ac5..ed63c344 100644 --- a/capistrano.gemspec +++ b/capistrano.gemspec @@ -28,7 +28,6 @@ Gem::Specification.new do |gem| gem.add_dependency "rake", ">= 10.0.0" gem.add_dependency "sshkit", ">= 1.9.0" - gem.add_development_dependency "danger" gem.add_development_dependency "mocha" gem.add_development_dependency "rspec" gem.add_development_dependency "rubocop", "0.48.1"