Copy whole dir and subdirs

April 16, 2007 at 20:24:59
Specs: DOS 6.0, Duron 800

Is there a way to copy a whole directory, files and subdirectories excluding a particular filename extension?

I want to copy all the dirs,files and subsdirs, but omit all files with .WRK extension. I am starting to think that this is easier to do with Linux and bash script...

See More: Copy whole dir and subdirs

Report •

April 16, 2007 at 22:15:49

DOS 6.0 unlikely:

.WRK is Windows Software Extension........

Report •

April 16, 2007 at 22:56:10

I think xxcopy will do that.


Report •

April 17, 2007 at 08:01:59

The 16bit version of XXCOPY will not work under NT O/Ses.........

DOS6.0 what is the real version ???

Report •

Related Solutions

April 17, 2007 at 12:43:24

Why not just use xcopy?

xcopy src dst /s/v/c/EXCLUDE:.wrk

Report •

April 17, 2007 at 14:59:28

Thanks for all your replies.

I need Long File Name support and LFNDOS and DOSLFN are pretty flakey.

I tried xxcopy, which works but is terribly slow and has no Long File Name support. I have also tried xcopy using both DOSLFN and LFNDOS.

I am having the best results using LCOPY from LFNTOOLS ( - GPL license) because it supports long filenames. It is also 20x faster than xxcopy. My only problem now is omitting certain file extensions with the copy- which is a big task in DOS.

To get this working, I think that I would have to dump a directory and file listing into a file then parse it in and check for a .WRK extension. This is A LOT of work in DOS for something that is simple, so I think I'll just drop it and do it with a Linux bash script.

DOS is v 6.22 BTW.

Thanks for all the help.

Report •

April 17, 2007 at 16:21:05

I don't see how you'll be able to use any utility to copy long file names since you're doing it from 6.22.

Report •

April 17, 2007 at 20:05:55

You can access NTFS drives with a program
called NTFS4DOS. You can download it for free. The program makes a bootdisk.
You can boot with any DOS disc and just
run the file NTFS4DOS.exe file. You then
have your NTFS drives.


Report •

April 17, 2007 at 20:25:31

Maybe I'm missing something but I think we're talking about dos 6.22 (which has no LFN support) and not an NTFS OS.

Report •

April 17, 2007 at 22:52:17

YEP, yet again trying to access NT O/Ses with a **-DOS Boot Disk.

Absolutely nothing to do with MS-DOS 6.22 par-se, a misguided OP!

Report •

April 20, 2007 at 09:32:28

NTFS4dos will read LFN. and won't rename the file.
It does such a good job that I Defrag
windows XP, Xp64bit 3.11, fat adn fat32 drives.
they boot just fine.
It can be done,


Report •

April 20, 2007 at 11:55:19

It's been awhile since I've used NTFS4DOS but as I recall, on the menu that first comes up you can choose to defrag. That defrag utility does preserve LFN. However its COPY command is a regular win 95 command and doesn't keep the LFN. Also I had problems with a simple COPY *.* . It would copy some but rarely all of the files in a directory. The rest I had to copy one at a time.

But my point is, since dos 6.22 doesn't create long file names there no reason to look for a copying utility that preserves LFN, nor will you find any that will work within dos 6.22.

Now maybe the poster is using another OS but for some reason wants to use dos 6.22 to copy the files. If that's the case he should have said so and maybe we could have provided better info.

Report •

Ask Question