Skip to content
Snippets Groups Projects

Change the approach to check if patches apply cleanly

Merged Rémy Coutable requested to merge 23372-fix-ce-to-ee-merge-check-task into master
All threads resolved!
Compare and Show latest version
2 files
+ 2
2
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -107,7 +107,7 @@ def generate_patch(branch, filepath)
@@ -107,7 +107,7 @@ def generate_patch(branch, filepath)
raise "#{branch} is too far behind master, please rebase it!" if depth > 500
raise "#{branch} is too far behind master, please rebase it!" if depth > 500
step("Generating the patch against master")
step("Generating the patch against master")
output, status = Gitlab::Popen.popen(%w[git format-patch origin/master --stdout])
output, status = Gitlab::Popen.popen(%w[git format-patch FETCH_HEAD --stdout])
throw(:halt_check, :ko) unless status.zero?
throw(:halt_check, :ko) unless status.zero?
File.open(filepath, 'w+') { |f| f.write(output) }
File.open(filepath, 'w+') { |f| f.write(output) }
Loading