summaryrefslogtreecommitdiffstats
path: root/urpm/sys.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-06-24 13:21:20 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-06-24 13:21:20 +0000
commit5d740abac49f175662254526c91acf2e130c8a6b (patch)
treeff2c17e0d0b809dda9b740e5b4652d53a8000048 /urpm/sys.pm
parent9e44fa13392197983dc413aba1097d8da287a006 (diff)
downloadurpmi-5d740abac49f175662254526c91acf2e130c8a6b.tar
urpmi-5d740abac49f175662254526c91acf2e130c8a6b.tar.gz
urpmi-5d740abac49f175662254526c91acf2e130c8a6b.tar.bz2
urpmi-5d740abac49f175662254526c91acf2e130c8a6b.tar.xz
urpmi-5d740abac49f175662254526c91acf2e130c8a6b.zip
empty_dir() is a better name, clean_dir() will be used for just removing the dir
Diffstat (limited to 'urpm/sys.pm')
-rw-r--r--urpm/sys.pm5
1 files changed, 5 insertions, 0 deletions
diff --git a/urpm/sys.pm b/urpm/sys.pm
index acbc5a9e..cf32d42c 100644
--- a/urpm/sys.pm
+++ b/urpm/sys.pm
@@ -257,6 +257,11 @@ sub clean_dir {
require File::Path;
File::Path::rmtree([$dir]);
+}
+
+sub empty_dir {
+ my ($dir) = @_;
+ clean_dir($dir);
mkdir $dir, 0755;
}