summaryrefslogtreecommitdiff
path: root/gentree.py
diff options
context:
space:
mode:
authorJohannes Berg <johannes@sipsolutions.net>2013-03-31 01:47:39 +0100
committerJohannes Berg <johannes@sipsolutions.net>2013-03-31 01:47:39 +0100
commit445920189178de0b338fc5fa6f3d52035f58c778 (patch)
tree5e1bdfd4877da968384a1bc0b0e76543db4cb39b /gentree.py
parent3149b038c8572bc8b66cb6747befcdbaa7487c2e (diff)
move orig/rej file removal
This needs to be after each patch. Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Diffstat (limited to 'gentree.py')
-rwxr-xr-xgentree.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/gentree.py b/gentree.py
index c766a0af..06aee47d 100755
--- a/gentree.py
+++ b/gentree.py
@@ -232,16 +232,16 @@ def main():
pfilef.write(diff)
pfilef.close()
os.unlink(fullfn + '.orig_file')
+ # remove orig/rej files that patch sometimes creates
+ for root, dirs, files in os.walk(args.outdir):
+ for f in files:
+ if f[-5:] == '.orig' or f[-4:] == '.rej':
+ os.unlink(os.path.join(root, f))
if not printed:
print "Not applying changes from %s, not needed" % (os.path.basename(pdir),)
else:
git_debug_snapshot(args, "apply backport patches from %s" % (os.path.basename(pdir),))
- # remove orig/rej files that patch sometimes creates
- for root, dirs, files in os.walk(args.outdir):
- for f in files:
- if f[-5:] == '.orig' or f[-4:] == '.rej':
- os.unlink(os.path.join(root, f))
# rewrite Makefile and source symbols
regexes = []