bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Feature request: rm option that supports trash (plain text)


From: Wilfred
Subject: Re: Feature request: rm option that supports trash (plain text)
Date: Sun, 10 Feb 2008 22:17:21 +0000

On 08/02/2008, Bob Proulx <address@hidden> wrote:
> Wilfred wrote:
> > address@hidden ~ $ mkdir testdel
> > address@hidden ~ $ alias del='mv --verbose --backup=simple
> > --suffix=$(date +".(%F_%T)") --target-directory=$HOME/.Trash/'
> > address@hidden ~ $ del testdel
> > mv: accessing `/home/wilfred/.Trash/': No such file or directory
>
> Right.  You would need to make the directory first.

This isn't a solution. I then have two trash directories, and the new
one isn't recognised by any trash handling applications. Moving files
to this new directory also does not record where the file came from
which makes restoring complex folder structures infeasible.

Trash is a solved problem and it would be nice not to reinvent the
wheel with simplistic scripts.

>

> The gentoo howto referenced in the FAQ may be more appropriate for you
> since there appears to be more actions to accomplish the task.

That script has the same problems I listed above.

> > http://www.ramendik.ru/docs/trashspec.html
>
> That URL times out for me and is not accessible.
>
Ok, try http://www.wilfred.me.uk/trashspec.html


> Since this is very easy to create using either an alias or a script it
> does seem like a good match to move this into the program itself.
> Utilities such as rm are intended to be building blocks to be used in
> applications.  They are not intended to be large all encompassing
> environments by themselves.  It is good to make designs modular and to
> build up more complex applications using simpler ones.
>
> Bob

I understand, and gnu coreutils is generally superb. However moving a
file to the trash is a sufficiently common operation that applications
currently have to implement themselves. I would have thought having
the functionality in rm would make sense.

Thanks for your time.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]