One failing rm should not block others

This commit is contained in:
Cheng Zhao 2015-07-03 14:40:32 +08:00
parent b30709f133
commit f87a4b9a04
2 changed files with 7 additions and 8 deletions

View file

@ -11,14 +11,11 @@ SOURCE_ROOT = os.path.abspath(os.path.dirname(os.path.dirname(__file__)))
def main():
os.chdir(SOURCE_ROOT)
try:
rm_rf('node_modules')
rm_rf('dist')
rm_rf('out')
rm_rf('spec/node_modules')
rm_rf('vendor/brightray/vendor/download/libchromiumcontent')
except WindowsError: # pylint: disable=E0602
pass
rm_rf('node_modules')
rm_rf('dist')
rm_rf('out')
rm_rf('spec/node_modules')
rm_rf('vendor/brightray/vendor/download/libchromiumcontent')
if __name__ == '__main__':

View file

@ -136,6 +136,8 @@ def rm_rf(path):
except OSError as e:
if e.errno != errno.ENOENT:
raise
except WindowsError: # pylint: disable=E0602
pass
def safe_unlink(path):