[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: what will happen to the --reply option?
From: |
Bob Proulx |
Subject: |
Re: what will happen to the --reply option? |
Date: |
Sun, 26 Aug 2007 02:48:10 -0600 |
User-agent: |
Mutt/1.5.9i |
Mark Rose wrote:
> Yeah, that's exactly the feature I've been wanting (only with mv instead of
> cp). I actually joined this list to figure out why it had been deprecated.
It was removed because it did not actually prevent overwriting files.
Try this with the old 'mv --reply=no'.
$ touch bar
$ date -R > foo
$ ls -ldgo foo bar
-rw-r--r-- 1 0 2007-08-26 02:33 bar
-rw-r--r-- 1 32 2007-08-26 02:33 foo
$ mv --reply=no foo bar
$ ls -ldgo foo bar
ls: foo: No such file or directory
-rw-r--r-- 1 32 2007-08-26 02:33 bar
Because mv would not prompt the file was overwritten. Using
'mv --reply=no' does not actually prevent overwriting files.
> One day, when I have time to fully understand the source code, I'll sit down
> and write a "--no-overwrite" patch for mv and cp that silently ignores
> moving/copying files when a file with the same name exists at the
> destination.
Sounds good.
Bob
Re: what will happen to the --reply option?, alessandro salvatori, 2007/08/26