diff options
author | Mark Spruiell <mes@zeroc.com> | 2002-10-31 00:08:11 +0000 |
---|---|---|
committer | Mark Spruiell <mes@zeroc.com> | 2002-10-31 00:08:11 +0000 |
commit | 827a0d05a3eb0e627acb187659ea0f531e19a1fc (patch) | |
tree | 7e12c6b37dbcfda0878f7edf4dba8ceacda77592 /cpp/makedist.py | |
parent | Wait for the service communicator to be shutdown before to close the (diff) | |
download | ice-827a0d05a3eb0e627acb187659ea0f531e19a1fc.tar.bz2 ice-827a0d05a3eb0e627acb187659ea0f531e19a1fc.tar.xz ice-827a0d05a3eb0e627acb187659ea0f531e19a1fc.zip |
more fixes
Diffstat (limited to 'cpp/makedist.py')
-rwxr-xr-x | cpp/makedist.py | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/cpp/makedist.py b/cpp/makedist.py index 9ac2ddf81b6..700b78082b7 100755 --- a/cpp/makedist.py +++ b/cpp/makedist.py @@ -16,17 +16,15 @@ import os, sys, fnmatch, re # -# Recursive removal of a directory. +# Remove a file or directory (recursive). # def rm(path): - files = os.listdir(path) - for x in files: - fullpath = os.path.join(path, x) - if os.path.isdir(fullpath) and not os.path.islink(fullpath): - rm(fullpath) - else: - os.remove(fullpath) - os.rmdir(path) + if os.path.isdir(path) and not os.path.islink(path): + for x in os.listdir(path): + rm(os.path.join(path, x)) + os.rmdir(path) + else: + os.remove(path) # # Find files matching a pattern. @@ -70,10 +68,10 @@ os.system("cvs -z5 -d cvs.mutablerealms.com:/home/cvsroot export " + tag + " ice # Remove files. # filesToRemove = [ \ - "makedist.py", \ + "ice/makedist.py", \ ] for x in filesToRemove: - os.remove(x) + rm(x) # # Generate bison files. |