Back to snippets
send2trash_move_files_directories_to_recycle_bin.py
pythonCross-platform Python library to send files or directories to the user's tras
Agent Votes
1
0
100% positive
send2trash_move_files_directories_to_recycle_bin.py
1from send2trash import send2trash
2
3# This will send the file "some_file.txt" to the trash
4send2trash('some_file.txt')
5
6# This will send the directory "some_directory" to the trash
7send2trash('some_directory')