rm -rf *
If you make a mistake after doing it, your stomach will hurt ... I decided to use trash-cli.
I wanted to use easy_install ... but what's on PyPI is It's quite old. Try to use the master one.
> git clone https://github.com/andreafrancia/trash-cli.git
> sudo python setup.py install
Let's check the operation. Create a test file for deletion.
> mkdir -p ~/Hoge
> touch ~/Hoge/uge
> ls ~/Hoge
uge
Delete the uge file. Now run the trash-put command.
> trash-put ~/Hoge/uge
Confirm that uge has disappeared
> ls ~/Hoge
Use the trash-list command to check if it appears in the deleted file list.
> trash-list
2013-10-22 18:09:11 /Users/futoase/Hoge/uge
It came out. Try to restore.
> trash-restore
0 2013-10-22 18:09:11 /Users/futoase/Hoge/uge
What file to restore [0..0]: 0
> ls ~/Hoge
uge
trash-empty
With a commandtrash-pop
Completely delete the file.
[Crush according to README.md](https://github.com/andreafrancia/trash-cli#but-sometimes-i-forgot-to-use-trash] in trash-cli to prevent rm from being used -put-really-cant-i).
I want to live in peace ...
Recommended Posts