patch.py: Use git format-patch with --no-signature --no-numbered params

* --no-signature saves unnecessary .patch modifications when executed on
  host with different git version
* --no-numbered saves unnecessary .patch modifications when number of the
  applied patches is changed (the number is still in the filename so the
  order how they should be applied is still preserved)
* both options exist for very long time, I've tested them with git 1.9.1
  from Ubuntu 14.04 and I'm quite sure they were available even in much
  older releases, so there shouldn't be any issue on relatively new sanity
  tested distros

(From OE-Core rev: ad76fa92c3a5be38962aff09df070ffd9756f777)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Martin Jansa 2018-03-15 22:50:10 +00:00 committed by Richard Purdie
parent 11032bebe8
commit 00b23ae2aa

View File

@ -448,7 +448,7 @@ class GitApplyTree(PatchTree):
import re
tempdir = tempfile.mkdtemp(prefix='oepatch')
try:
shellcmd = ["git", "format-patch", startcommit, "-o", tempdir]
shellcmd = ["git", "format-patch", "--no-signature", "--no-numbered", startcommit, "-o", tempdir]
if paths:
shellcmd.append('--')
shellcmd.extend(paths)