265
265
:param f: Patch file to read.
266
266
:param signoff: Add Signed-Off-By flag.
270
268
from dulwich.patch import git_am_patch_split
272
270
(c, diff, version) = git_am_patch_split(f)
273
271
# FIXME: Cope with git-specific bits in patch
274
272
# FIXME: Add new files to working tree
275
p = subprocess.Popen(["patch", "-p1"], stdin=subprocess.PIPE,
273
patch_tree(wt, [diff], strip=1, out=self.outf)
281
274
message = c.message.decode('utf-8')
283
276
signed_off_by = wt.branch.get_config().username()