Re: Getting the dir structure

2004-12-05 Thread Dan Jones
On Sat, 2004-12-04 at 17:25 -0800, John W. Krahn wrote: > Dan Jones wrote: > > On Thu, 2004-12-02 at 00:13 -0800, Mr M senthil kumar wrote: > > > >> > >> > >>>I have a file with thousands of line like : > >>>/abc/def/ijk/test.txt > >>>/pqr/lmn/test1.t > >>>I want to get the directory where the fi

Re: Getting the dir structure

2004-12-04 Thread John W. Krahn
Dan Jones wrote: On Thu, 2004-12-02 at 00:13 -0800, Mr M senthil kumar wrote: I have a file with thousands of line like : /abc/def/ijk/test.txt /pqr/lmn/test1.t I want to get the directory where the files test.txt and test1.txt are lying. Hi, You can try the following: #!/usr/bin/perl open (IN,"

Re: Getting the dir structure

2004-12-04 Thread Octavian Rasnita
All the files are automaticly closed when the perl program ends. Teddy - Original Message - From: "Dan Jones" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, December 05, 2004 1:25 AM Subject: Re: Getting the dir structure On Thu, 2004-12-02 at 00:

Re: Getting the dir structure

2004-12-04 Thread Dan Jones
On Thu, 2004-12-02 at 00:13 -0800, Mr M senthil kumar wrote: > > > > I have a file with thousands of line like : > > /abc/def/ijk/test.txt > > /pqr/lmn/test1.t > > I want to get the directory where the files test.txt and test1.txt are > > lying. > > > Hi, > You can try the following: > > #!/u

Re: Getting the dir structure

2004-12-02 Thread Mr M senthil kumar
> I have a file with thousands of line like : > /abc/def/ijk/test.txt > /pqr/lmn/test1.t > I want to get the directory where the files test.txt and test1.txt are > lying. Hi, You can try the following: #!/usr/bin/perl open (IN,"output_file") || die "Cannot send the output: $!"; while (){

RE: Getting the dir structure

2004-12-02 Thread Mallik
rs Subject: Re: Getting the dir structure On Thu, 2 Dec 2004, Nilay Puri, Noida wrote: > > I have a file with thousands of line like : > > /abc/def/ijk/test.txt > > /pqr/lmn/test1.t > > > > I want to get the directory where the files test.txt and test1.tx

Re: Getting the dir structure

2004-12-02 Thread Owen Cook
On Thu, 2 Dec 2004, Nilay Puri, Noida wrote: > > I have a file with thousands of line like : > > /abc/def/ijk/test.txt > > /pqr/lmn/test1.t > > > > I want to get the directory where the files test.txt and test1.txt are > lying. Try something like this ---