copy files from feed to listbox with folder structure

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
User avatar
calios
Junior Member
Junior Member
Posts: 20
Joined: 2006-08-28, 08:18 UTC

copy files from feed to listbox with folder structure

Post by *calios »

prerequisites:

folder with many files with same filename but in different subfolders:

\fruits\index.html
\cars\index.html

repro:
- do an ALT + F7 search for index.html
- click feed to listbox
- copy contents of listbox to new folder

problem:
howto copy the files from the listbox with a mirror copy of the folder structure they are in?

thoughts:
when i copy the files i surely can make tc rename them - but i loose the folder structure that would give context and meaning to the files having the same names.

when working on 10000+ files (all index.html) it is time consuming to go the other way around.

currently i need to:
- make a copy of the entire folder
- delete all except the files i want

now i hit the wall when i needed to only keep files containing a select string but not the other files with the same name.

is there a way tc supports this already that i missed?
for small problems: reboot your machine
for large problems: reinstall your machine
User avatar
ZoSTeR
Power Member
Power Member
Posts: 1052
Joined: 2004-07-29, 11:00 UTC

Post by *ZoSTeR »

The CopyTree plugin should do that.
Ralph
Member
Member
Posts: 100
Joined: 2004-08-21, 14:58 UTC
Location: USA

Post by *Ralph »

You can use Total Commander to copy both files and their directory structure from a listbox, if you are willing to create a ZIP file as an intermediate step. Packers other than ZIP probably would work also.
. Pack, using the option Also pack path names (only recursed).
. Either stop here, or unpack to the desired location, using the option Unpack path names if stored with files.

CopyTree (mentioned above) probably handles this task in one step. I have offered an alternative method because my employer restricts the software packages that I am allowed to use.
Last edited by Ralph on 2013-01-26, 15:51 UTC, edited 1 time in total.
krypton
Junior Member
Junior Member
Posts: 13
Joined: 2013-01-24, 18:04 UTC
Location: Italy

Re: copy files from feed to listbox with folder structure

Post by *krypton »

In the thread below I have proposed a solution for a problem like yours:

Title of the thread: Specific detail with the move funcionality

Code: Select all

ghisler.ch/board/viewtopic.php?t=36222

I can't post direct link, so copy & paste the link in your address bar or search thread by name.

edit: for doing what you want to obtain, my solution needs to be modified.
What are the extensions of the specific files you want to delete or maintain, are all .htm/.html?
The files you want to preserve are the majority or the minority of the overall files?
Ultimately, the files you want to keep have special characteristics that distinguish them from others? For example, it are stored in specific folders that don't change ever? How to recognize files of your interest?
Files have attributes?
Attributes are these:
R Read-only file attribute.
A Archive file attribute.
S System file attribute.
H Hidden file attribute.

(guide of attrib - command of cmd.exe)

For further information:

Code: Select all

technet.microsoft.com/en-us/library/bb490868
Or else read the guide of attrib in cmd.exe: open cmd.exe ---> typing: attrib /? --> press: ENTER.
Therefore, for example, you can assign attributes to the folders that contain your files or directly to the files by using attrib command or, much better, for do that you can also use the dialog box of TC: attributes, that is the first entry of the File menu in the program.
In the TC program's guide in this chapter ---> Dialog box: Change attributes, you can find a detailed description of the attributes and how to use the above-mentioned Dialog Box.
Then by using xcopy command, you can copy only the folders/files to which you have assigned attributes.
Post Reply