As per Tom's request, below is a short batch file to show the issue.
It appears that the DIR command prematurely terminates it's listing
without error if a directory bearing the same name is encountered.
As I understand it, the DIR command should make no distinction between
file and directory names?
And now back to work, the procrastinator that I am.
Here's what I did to demonstrate the problem in it's simplest form.
1. Take a clean flash drive and move to that drive.
2. Create a text file named "Q" in the root.
3. Create a batch file named demo.bat with contents below and run it.
CD \
MD A12
CD A12
MD Q
MD DEF
CD \
COPY Q A12\Q
COPY Q A12\DEF
4. Type command "DIR Q /S /B" Result below.
File Q is NOT shown in directory DEF.
f:\Q
f:\a12\q\Q
5. Type command "DIR Q. /S /B" Result below.
File Q is NOT shown in directory DEF.
f:\Q
f:\a12\q.\Q
6. Type command "DIR Q.? /S /B" Result below.
File Q is shown in directory DEF.
f:\Q
f:\a12\Q
f:\a12\def\Q
f:\a12\q\Q
7. Rename directory Q to QA
8. Type command "DIR Q /S /B" Result below.
File Q is shown in directory DEF.
f:\Q
f:\a12\def\Q
f:\a12\qa\Q
On 2024/06/04 19:48, tom ehlert wrote:
Hi
I think the issue is more complicated/ subtle than I first thought. If you
create the structure I showed, you will be able to reproduce the problem.
It would be cool if you posted a batch job that creates the structure, so we
would all talk about the
exact same thing, not something similar too each other.
and probably the command(s), too, as
IMO
DIR Q /S /B
and
DIR Q. /S /b
should result in the precisely same result.
Tom
_______________________________________________
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user