Re: write out filenames of files existing on a filesystem into a file

2006-07-10 Thread Dr.Ruud
"Nishi Bhonsle" schreef: > Can you please tell me how to modify the above program to ignore the > "." and "..", so that they donot get printed in C:/filelist.txt ? Since you want only files, see "perldoc -f -f". -- Affijn, Ruud "Gewoon is een tijger." -- To unsubscribe, e-mail: [EMAIL PROT

Re: write out filenames of files existing on a filesystem into a file

2006-07-08 Thread Mathew Snyder
The most direct way I can think of would be to simply open the file again and read each line writing it to another file exactly as you want. I'm still rather inexperienced with perl myself so I wouldn't know off-hand how to do this exactly. Mathew Nishi Bhonsle wrote: > Mathew: > > Thanks. I m

Re: write out filenames of files existing on a filesystem into a file

2006-07-07 Thread John W. Krahn
Nishi Bhonsle wrote: > I was able to writeout the files on a filesystem to a file C:/filelist.txt > using the program - > > $path = "$ARGV[0]"; > opendir ( DIR, $path ) or die "Can't open $path: $!"; > while(defined($DIR = readdir DIR)) > { > push(@array_A,$DIR) > } > closedir DIR; >

Re: write out filenames of files existing on a filesystem into a file

2006-07-07 Thread Nishi Bhonsle
I was able to writeout the files on a filesystem to a file C:/filelist.txt using the program - $path = "$ARGV[0]"; opendir ( DIR, $path ) or die "Can't open $path: $!"; while(defined($DIR = readdir DIR)) { push(@array_A,$DIR) } closedir DIR; open(FILE,">c:/filelist.txt"); foreach $y

Re: write out filenames of files existing on a filesystem into a file

2006-07-07 Thread Mr. Shawn H. Corey
Nishi Bhonsle wrote: > Hi: > > Can you please help me write a perl script that takes the files from a > directory and spits out the filenames into a file. > say. > I have a file structure on a file system such as > C:\Temp\one > C:\Temp\two > C:\Temp\one\oneone > C:\Temp\one\onetwo > C:\Temp\one\o