oberblastmeister / trashy

a cli system trash manager, alternative to rm and trash-cli
Apache License 2.0
362 stars 13 forks source link

Feature request: trash restore should only list items within current directory #77

Open omernaveedxyz opened 1 year ago

omernaveedxyz commented 1 year ago

Similar to how trash-cli handles restoring items, I would like for the ability to list items within only the current directory from which the command is executed from.

For example, if I am in ~/Downloads, the only items I would like to see from trash restore would be those whose original location was in ~/Downloads.

Using trash restore -d ./ does not work because it no longer prompts for the index of items to restore, but attempts to restore all items.

I've currently forked this repo and removed the check for filters within restore.rs (allowing trash restore -d ./ to still prompt for index) but I'm sure that is not ideal. Willing to consider any better implementations and put in a pull request if that would be helpful.