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

ruby-changes:63271

From: Nobuyoshi <ko1@a...>
Date: Mon, 5 Oct 2020 17:40:20 +0900 (JST)
Subject: [ruby-changes:63271] 82f496a84b (master): Put an empty line before the original URL

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

From 82f496a84b94d435b8b6fd80595151a08801b16c Mon Sep 17 00:00:00 2001
From: Nobuyoshi Nakada <nobu@r...>
Date: Mon, 5 Oct 2020 16:36:11 +0900
Subject: Put an empty line before the original URL

Even if the raw commit log does not end with a newline.
Suggested to use `grep` by znz.

Co-Authored-By: Kazuhiro NISHIYAMA <zn@m...>

diff --git a/tool/sync_default_gems.rb b/tool/sync_default_gems.rb
index 236c16a..c6d64e9 100644
--- a/tool/sync_default_gems.rb
+++ b/tool/sync_default_gems.rb
@@ -399,7 +399,7 @@ def sync_default_gems_with_commits(gem, ranges, edit: nil) https://github.com/ruby/ruby/blob/trunk/tool/sync_default_gems.rb#L399
 
     prefix = "[#{(REPOSITORIES[gem.to_sym])}]".gsub(/\//, '\/')
     suffix = "https://github.com/#{(REPOSITORIES[gem.to_sym])}/commit/#{sha[0,10]}"
-    `git filter-branch -f --msg-filter 'sed "1s/^/#{prefix} /" && echo && echo #{suffix}' -- HEAD~1..HEAD`
+    `git filter-branch -f --msg-filter 'grep "" - | sed "1s/^/#{prefix} /" && echo && echo #{suffix}' -- HEAD~1..HEAD`
     unless $?.success?
       puts "Failed to modify commit message of #{sha}"
       break
-- 
cgit v0.10.2


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

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