Topic "Move everything in a directory but exclude sub-directories"

Author Message
tava
[View user's profile]

Joined: 2013-02-21
Posts: 2
Hi,

I've read the scripting section & forums for this issue but can't seem to find it regarding MOVE command. If it has been said already really sorry.

I have a default folder called "HOME" and inside HOME sits bunch of files (e.g. 1.txt, 2.csv, 3.xls, 4.pdf ...etc) Also in the HOME Folder sits a subdirectory called "HOLDING".

Part of my command I use the Syntax "mv *.* /HOME/HOLDING/" this starts to move all files (1.txt,2.csv etc) into HOLDING however, it then starts to move HOLDING into its own folder and fails with with a permission Error "Cant Move Holding into Holding" which makes perfect sense.

How do i exclude "HOLDING" from being moved as well. I've tried

- Option exclude "*/" -Doesn't work
- Option exclude "/HOLDING/" (as well as "/HOLDING" , "*/HOME/HOLDING")

Any ideas I'm also using WINSCP 4.3.5 (Build 1463) - not sure if this makes a difference but ideally i dont wish to update if not required)

Thanks

Tava

Edit: Spelling Errors
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
This is not supported yet.
Request is tracked here:
http://winscp.net/tracker/show_bug.cgi?id=704
tava
[View user's profile]

Joined: 2013-02-21
Posts: 2
prikryl wrote:
This is not supported yet.
Request is tracked here:
http://winscp.net/tracker/show_bug.cgi?id=704



Thanks for the quick reply, this issue was originally logged in 2011 by another user, since it hasn't been fixed are you looking at a quick resolution.

Work around I'm using at the moment is MV command with list of file types we expect to get sent to us & common extensions.

Thanks again,
Tava
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License