4

I'm the developer of the trash-cli project.

The trash-cli project is a opensource implementation of the FreeDesktop.org Trash Specification that provides a command line interface to manage the trashcan.

Ideally trash-cli provides these commands:

  • trash (trashes files and directories)
  • trash-empty (empty the trashcan(s))
  • trash-list (list trashed files)
  • trash-restore (restore a trashed file)

But I must rename the 'trash' command because the name is too generic to let the trash-cli added in Fedora (see full discussion here)

I chose the 'trash' name because I think is the better name you could use (is short and intuitive), but, as I stated before, I can't use this name.

In any case I think a good choice keep the trash-* form because it exploit the shell TAB completion.

In the beginning I was persuaded to rename the 'trash' command in 'trash-file' but I don't like it very much, and as Christoph Bloch pointed out:

My arguments against "trash-file": * It is not intuitive and therefore unnecessarily difficult to memorise. * It is unnecessarily long. * Every change in the name of programs causes confusion, so the new solution should be a clear improvement (which it isn't). * It is even wrong: Directories can be trashed, too.

Just "trash" was much better.

I collected some ideas for renamng the 'trash' command. Would you like help me to choose the best one? Do you know a better name?

Here the alternatives (some of them are ugly, I know it, but maybe they help you to find a better name) :

  • trash-put
  • trash-put-in
  • trash-trash
  • trash-throw
  • trash-f
  • trash-rm
  • trash-recycle
  • trash-do
  • trash-to

  • trash-

  • trash-now
  • trash-!
  • trash2
  • trash
  • trashit

  • trash-item

  • trash-entry
  • trash-elem
  • trash-path
  • trash-data

  • trash-this

  • trash-it
  • trash-that
4

6 回答 6

5

Perhaps go the 'UNIX way' and adopt as short a name as possible.

tf? - although the objection that it also handles directories remains.

Note that the word 'trash' is perceived in Britain to be an Americanism. I'm not sure about other English speaking countries. Apple clearly didn't care about non-American sensibilities when they named the Trash Can. I guess Red Hat didn't either (or just followed Apple's cue).

于 2009-01-04T00:26:41.463 回答
3

Why not have a single command with different arguments for the actions you want?

trash list
trash empty
trash restore {<file>}*

I realize this goes against the UNIX-way in the strictest sense, however, they are all operations on a single object, so I'd make the argument there should be one command for this rather than a group of commands.


As far as renaming "trash" to something else, really? Wow, I think "trash" is actually pretty intuitive compared to the alternatives. Some alternatives:

  • trashcan, or simply tc
  • wastebasket, or simply wb
于 2009-01-04T01:06:01.807 回答
1

How about just:

trashcan-put trashcan-*

于 2009-01-04T00:30:17.510 回答
1

trash-put (for brevity and clarity) or trash-this (for ease of typing, as this is made up of readily-typed characters -- especially to an OO programmer ;-)

于 2009-01-04T13:33:40.550 回答
0

Perhaps a different synonym altogether would be better?

  • discard
  • fling
  • toss
  • chuck
  • dispose
  • scrap
  • junk
  • recycle
于 2009-01-04T00:14:14.250 回答
0

Thanks to all.

I seems that -put is the preferred one. Also in the distributions@lists.freedesktop.org mailing list I received the positive feedback for this command.

Probably the command names will be:

  • trash-put (put files (or directories) in the trashcan)
  • trash-empty (empty the trashcan(s))
  • trash-list (list trashed files)
  • trash-restore (restore a trashed file)
于 2009-01-04T15:15:02.387 回答