changeset 24905:4ecbd88cde9a

keyword: use wvfs.rmtree to remove kwdemo directory Pass repo.root explicitly as argument to indicate that removal of the temporary repo is intentional in this case.
author Christian Ebert <blacktrash@gmx.net>
date Sat, 18 Apr 2015 15:39:26 +0200
parents e9edd53770fb
children 9570587b6986
files hgext/keyword.py
diffstat 1 files changed, 1 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/keyword.py	Wed Apr 22 15:03:09 2015 -0700
+++ b/hgext/keyword.py	Sat Apr 18 15:39:26 2015 +0200
@@ -457,9 +457,7 @@
     repo.commit(text=msg)
     ui.status(_('\n\tkeywords expanded\n'))
     ui.write(repo.wread(fn))
-    for root, dirs, files in os.walk(tmpdir):
-        for f in files:
-            util.unlinkpath(repo.vfs.reljoin(root, f))
+    repo.wvfs.rmtree(repo.root)
 
 @command('kwexpand',
     commands.walkopts,