Hacker News new | ask | show | jobs
by Amine_Ztn 1348 days ago
You are totally right, thank you for the pertinent comment and I will correct that. This is one of the first cli's I had not thought of at all.
2 comments

I think the trash interaction command needs to be a different main command, actually. No matter what you call the option, someone can make a file with that name.
Usually tools support a `--` option for that, e.g. with `rm`:

  rm -- --file-that-looks-like-a-flag

    rm ./--file-that-looks-like-a-flag
;)

(I'm always half-tempted to suggest that a "strict mode" shell should require all paths in arguments to start with either / or ./ so that anything else is unambiguously not a file.)

(I spent a bunch of time with a file named -i in my home directory, you know, just in case.)

At least globbing should return fully qualified paths (not sure there is an established term for `(<directory>/)+<file>' paths, as opposed to `<file>` ones).
thank you for your feedback, I take it all into consideration, I will try to fix it during the day :D
I agree. rmt-flush and rmt-list would be great options.
Also, the `trash_` is redundant, so `rmt --display` et cetera is all enough (and please make short options like `-d` too).