Union site: www.cn-dos.net Forum site: www.cn-dos.net/forum
DOS stands for freedom, openness and progress. Let us work hard, learn from the openness and GNU spirit of FreeDOS and Linux, and together build and grow a free GNU GPL world!
Credits 90 Posts 35 Joined 2006-10-23 01:13 19-year member UID 67781 Gender Male
Status Offline
There is a folder named 1 on drive D. Inside the 1 folder, there are 3 folders: 2, 3, and 4. What command can be used to list the name of each folder per line, with the purpose of comparing 2 folders? Thanks
Credits 439 Posts 170 Joined 2006-01-09 20:29 20-year member UID 48707
Status Offline
C:\>dir /?
Displays a list of files and subdirectories in a directory.
DIR at
sortorder]]
Specifies the drive, directory
/A Displays files with specified attributes.
attributes D Directory
H Hidden file
S System file
/B Uses bare format (no header information or
/C Shows thousand separator in file sizes.
Disables separator display.
/D Same as wide but files are listed by columns
/L Uses lowercase.
/N New long list format where files
/O Lists files in sorted order.
sortorder N By name (alphabetically)
E By extension (alphabetically)
G Group directories first - Reverse
/P Pauses after each screenful of information.
/Q Displays file owner.
/S Displays specified directory and all subdirectories
/T Controls which time to display or use for sorting
timefield C Creation time
A Last access time
W Last write time
/W Uses wide list format.
/X Displays the short name generated for non 8dot3 filenames
The short name is inserted before the long name. If
displays blank.
/4 Uses four-digit year
You can predefine command options in the DIRCMD environment variable
to override the pre-set command options, for example, /-W.
Credits 90 Posts 35 Joined 2006-10-23 01:13 19-year member UID 67781 Gender Male
Status Offline
I find that I'm still quite inexperienced. There's another question. There are many lines in a text. How to read one line of text each time, from the first line all the way to the last line!
Credits 2,725 Posts 1,160 Joined 2006-09-23 12:00 19-year member UID 63486 From 河北廊坊
Status Offline
Brothers and sisters, please try to search before asking questions. Maybe you can find the answer without asking;
Brothers and sisters, please try to be clear when answering questions. We rookies hope to get sincere help.