Skip to content

Commit 194f4a1

Browse files
Add patch option to apply pre-committed CRuby patches
1 parent a2ffc0c commit 194f4a1

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Rakefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ BUILD_SOURCES = [
88
type: "github",
99
repo: "ruby/ruby",
1010
rev: "master",
11+
patches: [],
1112
},
1213
]
1314

@@ -72,6 +73,10 @@ class BuildSource
7273
else
7374
raise "unknown source type: #{@params[:type]}"
7475
end
76+
(@params[:patches] || []).each do |patch_path|
77+
patch_file = "#{@base_dir}/#{patch_path}"
78+
sh "patch -p1 < #{patch_file}", chdir: src_dir
79+
end
7580
end
7681
end
7782

0 commit comments

Comments
 (0)