diff options
author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2023-05-02 09:09:17 +0900 |
---|---|---|
committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2023-05-02 18:27:10 +0900 |
commit | 31774bd56506c49823c0b77a2ab025775e64ff26 (patch) | |
tree | 8bd3959ce749a13bd9b93ca99ca620195e69d7a0 /tool | |
parent | b15e88e0fcccb03b9cc5e4c1478ec9b10e26c961 (diff) |
Remove `sync_tool` task from Rakefile when syncing [ci skip]
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/7780
Diffstat (limited to 'tool')
-rwxr-xr-x | tool/sync_test_lib.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tool/sync_test_lib.rb b/tool/sync_test_lib.rb index 904fa42d02..23ca4a1154 100755 --- a/tool/sync_test_lib.rb +++ b/tool/sync_test_lib.rb @@ -76,6 +76,12 @@ repos.each do |repo| system "git add #{file}" end + rf = File.binread("Rakefile") + if rf.sub!(/(?>\A|(\n)\n*)task +:sync_tool +do\n(?>(?> .*)?\n)*end\n(?=\z|(\n))/) {$1&&$2} + File.binwrite("Rakefile", rf) + system "git add Rakefile" + end + if IO.popen(%W"git commit -m #{title}\n\n#{message}", &:read).chomp =~ /nothing to commit/ puts "#{repo}: nothing to update" elsif update |