Skip to content

Commit

Permalink
Use rmtree
Browse files Browse the repository at this point in the history
  • Loading branch information
Neves-P committed Jul 2, 2024
1 parent 59a337c commit f80ab2b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks/clean_up.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def move_to_trash_bin(trash_bin_dir, job_dirs):
for pr_dir in pr_dirs:
destination_dir = shutil.copytree(pr_dir, trash_bin_dir)
log(f"{funcname}(): copied {pr_dir} to {destination_dir}")
os.remove(pr_dir)
shutil.rmtree(pr_dir) # Use shutil.rmtree to remove directories recursively
log(f"{funcname}(): removed {pr_dir}")

return True

0 comments on commit f80ab2b

Please sign in to comment.