forked from sebras/buerg
-
Notifications
You must be signed in to change notification settings - Fork 0
/
LDIR.DOC
182 lines (125 loc) · 4.87 KB
/
LDIR.DOC
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
LDIR Command Version 4.4
----------- Mar 25, 1991
Purpose: To display the files in one or all directories of a disk.
Format: LDIR [d:][\path]filespec] [/?... /?]
Remarks: If no operands are supplied, the files in the current path
and in the current directory are displayed. You may specify
another drive using the d: operand, and/or a path name,
and/or a file specification. Wildcard characters * and ? are
permitted in the filespec operand.
All available memory is used. As many files as fit in memory
are sorted and displayed.
The /? refers to optional processing switches. You may use
one or more of the following:
Sort options:
/D sort by file Date
/F sort by File name
/N no sorting of DIR entries
/S sort by file Size
/X sort by eXtension
File criteria:
/A include Attributes, e.g. S=system, R=readonly, H=hidden
/H include files with the Hidden attribute
/M display only Modified files, i.e with Archive bit off
/P include all Paths starting with the current directory
Display options:
/C Clear screen first, and after any "... more" prompts
/W Wait after screen full, ask for any key after 20 lines displayed
/? display usage syntax
LDIR Command Version 4.4
----------- Mar 25, 1991
Examples
--------
o Display all files, in filename order, on the current drive:
LDIR
o Display all files in the subdirectory \TEST\PGMS on drive B:
LDIR B:\TEST\PGMS
o Display only those files with an extension of .COM in the
current directory which is not a root directory:
LDIR *.COM
o Display all modified files in all subdirectories on current drive
and place the output in the file called DIRLIST on drive C:
LDIR /M/P >C:DIRLIST
LDIR Command Version 4.4
----------- Mar 25, 1991
Changing defaults
-----------------
The default option is to sort by file name. You may use DEBUG
to permanently change this default. The bytes called FLAG1
and FLAG2 contain the option indicators.
Field Offset Option Hex and bit values
----- ------ ------ -----------------------------------
FLAG1 0111 A 01 .... ...1
H 02 .... ..1.
C 04 .... .1..
D 08 .... 1...
X 10 ...1 ....
F 40 .1.. ....
S 80 1... ....
FLAG2 0112 M 01 .... ...1
W 02 .... ..1.
P 20 ..1. ....
For example, to change to defaults to /A/P/D/F/W:
FLAG1 becomes 01 + 08 + 40, (A and D and F),
FLAG2 becomes 02 + 20 = 22, (W and P).
DEBUG LDIR.COM
-e 10d 49 (should originally be 40)
-e 10e 22 (should originally be 00)
-w
-q
Notes
-----
Written for the IBM PC using DOS 2.0 or later, including DOS 3.3.
For private use only. May not be sold.
Copyright 1986-89 by Vernon D. Buerg. All rights reserved.
139 White Oak Circle
Petaluma, CA 94952
BBS: (707) 778-8944
CompuServe: 70007,1212
LDIR Command Version 4.4
----------- Mar 25, 1991
Version History
---------------
Version 2.3, August 10, 1985
Correct some problems with path\filespec syntax
Adds /M option to list modified files only
Version 2.4, October 28, 1985
Adds /W option to pause after 20 lines are displayed
Speeds up screen displays but defeats redirection
Version 2.5, November 5, 1985
Minor changes for color displays
Version 2.6, January 4, 1986
By popular demand, ability for redirection and
use of PrtSc restored at the price of slower displays.
Problem changing current directory fixed.
Version 2.7, February 15, 1986
Minor corrections to command line syntax checking
Version 2.8, April 22, 1986
A special request version that does NO sorting of
the directory entries. The directory is displayed
in its original order. This is now the /N option.
Version 2.9, May 12, 1986
Corrects problem changing the current directory of
the current drive when LDIR is used for a subdir on
another drive.
Version 3.0, June 4, 1986
Corrects a problem when DEBUG is used to change
the default option switches. The attribute mask
used to read directories was not being updated.
Version 3.1, Dec 28, 1986
Version 3.2, June 12, 1987
Corrects problem specifying a filespec when in a
subdirectory, e.g. LDIR *.ASM failed.
Version 4.1, Jan 25, 1989
Expands the number of file names from 1000 to an amount
determined by available memory. Approximately 64 bytes
per file name is required. In other words, 64K bytes of
memory is required for each 1000 files.
Version 4.3, Dec 14, 1989
Change display of bytes used and free to allow values
over 100 million; add commas. Also correct failure to
clear the screen if the /C option is set by DEBUG.
Version 4.4, Mar 25, 1991
Correct handling of /N no sort option when /A or /H
is also specified.