diff options
author | Aneesh Agrawal <aneeshusa@gmail.com> | 2017-04-16 16:01:54 -0400 |
---|---|---|
committer | Aneesh Agrawal <aneeshusa@gmail.com> | 2017-04-18 09:30:41 -0400 |
commit | b1824f7a05078910e16ba466f107c1a3db6839cd (patch) | |
tree | 291d4bd20827a95d1cc51d44517ebf22bab3ba24 /python/servo/package_commands.py | |
parent | 7413c716fb954c1dd27c39929e27bd7b4b188720 (diff) | |
download | servo-b1824f7a05078910e16ba466f107c1a3db6839cd.tar.gz servo-b1824f7a05078910e16ba466f107c1a3db6839cd.zip |
Move delete function to util.py
This makes it easier to reuse in other places.
Diffstat (limited to 'python/servo/package_commands.py')
-rw-r--r-- | python/servo/package_commands.py | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/python/servo/package_commands.py b/python/servo/package_commands.py index 68569838c4c..9abffc603e5 100644 --- a/python/servo/package_commands.py +++ b/python/servo/package_commands.py @@ -33,13 +33,7 @@ from servo.command_base import ( is_windows, get_browserhtml_path, ) - - -def delete(path): - try: - os.remove(path) # Succeeds if path was a file - except OSError: # Or, if path was a directory... - shutil.rmtree(path) # Remove it and all its contents. +from servo.util import delete def otool(s): |