5 # Process command line arguments.
6 while ($ARGV[0] =~ /^-/)
16 die "unknown command line option";
20 # Determine directory to run this on.
21 @findDirs = @ARGV ?
@ARGV : ('.');
23 # Scan for appropriate files.
24 find
(\
&FindHandler
, @findDirs);
29 # ===================================================================
35 # Examining a directory entry.
37 # Prune the directory if it's one I want to ignore. This
38 # stops the program from descending any further down this directory.
39 if (m/^(compile|external|Debug|Optimized|Production|Release)$/i)
42 $File::Find
::prune
= 1;
43 print STDERR
"[Pruned Directory Entry: $File::Find::name]\n" if ($debug);
48 # Handle files that should go in the workspace file.
49 if (m/^.*(c|cpp|def|h|hpp|java|lnt|pl|pm|py|script(?:lib)?|sql|tab|txt)$/)
51 print "$_:$File::Find::dir/\n";
56 # ===================================================================