This commit is contained in:
sukanka 2022-08-10 20:21:11 +08:00
parent e381911ae1
commit 10b48ea3f7
4 changed files with 4 additions and 4 deletions

View file

@ -3,7 +3,7 @@ from lilaclib import *
def apply_patch(filename, patch,reverse=False):
rev="-R" if revert else ""
rev="-R" if reverse else ""
patch_proc = subprocess.Popen(
["patch", "-p1", rev, filename], stdin=subprocess.PIPE, text=True)
patch_proc.communicate(patch)

View file

@ -3,7 +3,7 @@ from lilaclib import *
def apply_patch(filename, patch, reverse=False):
rev = "-R" if revert else ""
rev = "-R" if reverse else ""
patch_proc = subprocess.Popen(
["patch", "-p1", rev, filename], stdin=subprocess.PIPE, text=True)
patch_proc.communicate(patch)

View file

@ -3,7 +3,7 @@ from lilaclib import *
def apply_patch(filename, patch, reverse=False):
rev = "-R" if revert else ""
rev = "-R" if reverse else ""
patch_proc = subprocess.Popen(
["patch", "-p1", rev, filename], stdin=subprocess.PIPE, text=True)
patch_proc.communicate(patch)

View file

@ -3,7 +3,7 @@ from lilaclib import *
def apply_patch(filename, patch, reverse=False):
rev = "-R" if revert else ""
rev = "-R" if reverse else ""
patch_proc = subprocess.Popen(
["patch", "-p1", rev, filename], stdin=subprocess.PIPE, text=True)
patch_proc.communicate(patch)