andreafrancia / trash-cli

Command line interface to the freedesktop.org trashcan.
GNU General Public License v2.0
3.53k stars 177 forks source link

`trash-empty` empty only PWD trashcan (like `trash-restore` does) #302

Open Andrew15-5 opened 1 year ago

Andrew15-5 commented 1 year ago

Is your feature request related to a problem? Please describe.

I use lf with trash-cli and I can't empty only one of many trashcans. But I can empty all of them or empty all of them from all users or empty --trash-dir which wants a valid trashcan path (I don't know how to get it without making a whole script file).

Describe the solution you'd like I want trash-empty to work as the trash-restore command, which will automatically only list files from the current trashcan. Or add an option like --local-trash-dir.

Describe alternatives you've considered

I can in theory whip up a script that will give me a valid trashcan path and then use it with --trash-dir option, but it probably wouldn't be concise and readable, so I don't think that would be a great idea.

Additional context trash-cli: 0.23.2.13.2