265
266
:param f: Patch file to read.
266
267
:param signoff: Add Signed-Off-By flag.
270
269
from dulwich.patch import git_am_patch_split
272
271
(c, diff, version) = git_am_patch_split(f)
273
272
# FIXME: Cope with git-specific bits in patch
274
273
# FIXME: Add new files to working tree
275
p = subprocess.Popen(["patch", "-p1"], stdin=subprocess.PIPE,
274
patch_tree(wt, [diff], strip=1, out=self.outf)
283
277
signed_off_by = wt.branch.get_config().username()
287
281
def run(self, patches_list=None, signoff=False, force=False):
288
282
from ..errors import UncommittedChanges