[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Bug-coreutils Digest, Vol 40, Issue 16
From: |
Javier Acuña |
Subject: |
Re: Bug-coreutils Digest, Vol 40, Issue 16 |
Date: |
Thu, 23 Mar 2006 13:51:08 -0400 |
Hello all
I believe this has been discussed before.
Check http://64.62.136.189/address@hidden/msg04338.html
" Christian Boltz wrote:
> I just found a bug in mv: it overwrites files even when --reply=no is
> given (which should never overwrite existing files according to the
> documentation).
This has become a hot topic. Please read this thread to catch up on
the happenings.
http://lists.gnu.org/archive/html/bug-coreutils/2005-06/msg00160.html
Bob"
My personal solution is a small shell script:
#! /bin/bash
# Usage $mv_preserve.sh folder_1 folder_2
# $1 == folder 1
# $2 == folder 2
# Written by Javier Acuna address@hidden
for file in $1/*; do
# ${file/$1/$2} replaces the first folder from the path with the second folder
if [ -e ${file/$1/$2} ]
then echo "preserving $2/$file"
rm $file
else
mv $file ${file/$1/$2}
fi
done
Best Regards
Javier Acuna
>
>Message: 1
>Date: Thu, 23 Mar 2006 12:21:16 +0300
>From: "address@hidden" <address@hidden>
>Subject: Bug in util mv
>To: address@hidden
>Message-ID: <address@hidden>
>Content-Type: text/plain; charset=KOI8-R; format=flowed
>
>In version 5.2.1 of command mv "-i --reply=no" and "--reply=no" work as
>"--reply=yes".
>"--reply=no" not works.
>
>Sorry for my english. %)
>
>Good luck.
________________________________________________________________
Mensaje enviado desde el Servicio Webmail del Dominio sixbell.cl
_____________________________
La informacion contenida en esta transmision es confidencial, y no puede ser
usada por otras personas que su(s) destinatario(s). El uso no autorizado de la
informacion contenida en esta transmision puede ser sancionado. Si ha recibido
esta transmision por error, por favor destruyala y notifique al remitente
telefonicamente, con cobro revertido o via e-mail.
The information contained in this transmission is privileged, and may not be
used by any person other than its addressee(s). Unauthorized use of the
information contained in this transmission may be punished by law. If
received in error, please destroy and notify the sender by calling collect or
by e-mail.
_____________________________
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: Bug-coreutils Digest, Vol 40, Issue 16,
Javier Acuña <=