Re: Problem overwriting files with mv commant
@tomer: Sorry, indeed, the change was rolled back in the end. You can vote for it to be implemented in the tracker.
Since 6.0,mv
overwrites the existing files:
Issue 2185 – Allow overwriting existing files when moving/renaming in scripting/.NET assembly
mv
overwrites the existing files:
call mv -f *
worked for me.
1. Is there a option to overwrite?
2. If 1 is not possible; is there a option to send an email (write some script within winscp) saying overwrite failed.
Are there any future enhancements to the product with Move (mv
) having the overwrite facility?
mv
) having the overwrite facility?
1.get
(remote file to local directory)
2.delete
(remote file in original directory)
3.put
(local file on destination remote directory)
delete
(remote file in destination directory)
mv
(move remote file from original to destination directory)
cp
command (edit 2021: there's cp
command now).
Can you then confirm that option 3. will allow for an overwrite as I can't see it in the switches list forput
?
option confirm off
get
(remote file to local directory)
delete
(remote file in original directory)
put
(local file on destination remote directory)
put
?
cp
command that was mentioned? I can't find any references to it?
cp
command followed by the delete
command, both using the wildcards.
mv
command to do this as follows:
mv lcenewbkg-*.csv /home/samba/archive-bkgdata/
archive-bkgdata
folder, the mv
command does not move the files. If I use the GUI to move them manually, I am presented with a message to overwrite the file, but there doesn't seem to be any such option for scripting the mv
command. Am I missing something?
batch on
and confirm off
, but I understand these are not relevant for the mv
command.
mv
command to always overwrite the files in the remote folder? Or is there another way of doing it?