[前][次][番号順一覧][スレッド一覧]

ruby-changes:62234

From: Utkarsh <ko1@a...>
Date: Wed, 15 Jul 2020 16:05:50 +0900 (JST)
Subject: [ruby-changes:62234] ca133c0366 (master): [rubygems/rubygems] Fix line spacing to make Layout/EmptyLines happy

https://git.ruby-lang.org/ruby.git/commit/?id=ca133c0366

From ca133c03669d495d297579e1f14bc904db591e1d Mon Sep 17 00:00:00 2001
From: Utkarsh Gupta <utkarsh@d...>
Date: Tue, 30 Jun 2020 14:42:59 +0530
Subject: [rubygems/rubygems] Fix line spacing to make Layout/EmptyLines happy

The Gemfile wasn't properly put in the last commit.
As a result, Layout/EmptyLines inspected an offense
in the Gemfile.

This also fixes the spec w.r.t change in the task
default.

Signed-off-by: Utkarsh Gupta <utkarsh@d...>

https://github.com/rubygems/rubygems/commit/d1418fddd3

diff --git a/lib/bundler/templates/newgem/Gemfile.tt b/lib/bundler/templates/newgem/Gemfile.tt
index 82504f9..1d55fd7 100644
--- a/lib/bundler/templates/newgem/Gemfile.tt
+++ b/lib/bundler/templates/newgem/Gemfile.tt
@@ -7,13 +7,14 @@ gemspec https://github.com/ruby/ruby/blob/trunk/lib/bundler/templates/newgem/Gemfile.tt#L7
 
 gem "rake", "~> 13.0"
 <%- if config[:ext] -%>
+
 gem "rake-compiler"
 <%- end -%>
-
 <%- if config[:test] -%>
+
 gem "<%= config[:test] %>", "~> <%= config[:test_framework_version] %>"
 <%- end -%>
-
 <%- if config[:rubocop] -%>
+
 gem "rubocop", "~> 0.80"
 <%- end -%>
diff --git a/spec/bundler/commands/newgem_spec.rb b/spec/bundler/commands/newgem_spec.rb
index 16ce9de..4180653 100644
--- a/spec/bundler/commands/newgem_spec.rb
+++ b/spec/bundler/commands/newgem_spec.rb
@@ -914,7 +914,7 @@ RSpec.describe "bundle gem" do https://github.com/ruby/ruby/blob/trunk/spec/bundler/commands/newgem_spec.rb#L914
             ext.lib_dir = "lib/#{gem_name}"
           end
 
-          task default: [:clobber, :compile]
+          task default: %i[clobber compile]
         RAKEFILE
 
         expect(bundled_app("#{gem_name}/Rakefile").read).to eq(rakefile)
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]