Rev 30 | Rev 37 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 30 | Rev 31 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | program filefind; |
1 | program filefind; |
2 | Uses sysutils; |
2 | Uses sysutils; |
3 | var directory : string; |
3 | var directory : string; |
4 | 4 | ||
- | 5 | // ============================================================================ |
|
- | 6 | // Functions |
|
- | 7 | // ============================================================================ |
|
- | 8 | ||
5 | procedure traverse(directory : string); |
9 | procedure traverse(directory : string); |
6 | var curdir1, curdir2 : string; |
10 | var curdir1, curdir2 : string; |
7 | Info : TSearchRec; |
11 | Info : TSearchRec; |
8 | pfile : string; |
12 | pfile : string; |
9 | begin |
13 | begin |
Line 28... | Line 32... | ||
28 | procedure start_traverse(directory : string); |
32 | procedure start_traverse(directory : string); |
29 | begin |
33 | begin |
30 | Writeln(directory); |
34 | Writeln(directory); |
31 | traverse(directory); |
35 | traverse(directory); |
32 | end; |
36 | end; |
- | 37 | ||
- | 38 | // ============================================================================ |
|
- | 39 | // Main |
|
- | 40 | // ============================================================================ |
|
33 | 41 | ||
34 | begin |
42 | begin |
35 | directory := ParamStr(1); |
43 | directory := ParamStr(1); |
36 | if (ParamCount = 1) |
44 | if (ParamCount = 1) |
37 | then |
45 | then |