sort files by creation time

2005-12-12 Thread Brian Volk
Hi All~ I'm using the glob function to grab all the files in a given directory and then using crontab to check it every 5 minutes. Once I have the files I'm using the diamond operator to read every line in every file and *do something* if the line matches. Here's my questions: Given dire

Re: sort files by creation time

2005-12-12 Thread Bob Showalter
Brian Volk wrote: Hi All~ I'm using the glob function to grab all the files in a given directory and then using crontab to check it every 5 minutes. Once I have the files I'm using the diamond operator to read every line in every file and *do something* if the line matches. Here's my ques

RE: sort files by creation time

2005-12-12 Thread Brian Volk
:33 PM To: 'beginners@perl.org' Subject: sort files by creation time Hi All~ I'm using the glob function to grab all the files in a given directory and then using crontab to check it every 5 minutes. Once I have the files I'm using the diamond operator to read every line in

RE: sort files by creation time

2005-12-12 Thread Timothy Johnson
} -Original Message- From: Brian Volk [mailto:[EMAIL PROTECTED] Sent: Monday, December 12, 2005 9:33 AM To: 'beginners@perl.org' Subject: sort files by creation time Hi All~ I would like to process the File 1 first then Fil

RE: sort files by creation time

2005-12-12 Thread Ryan Frantz
> -Original Message- > From: Brian Volk [mailto:[EMAIL PROTECTED] > Sent: Monday, December 12, 2005 4:47 PM > To: beginners@perl.org > Subject: RE: sort files by creation time > > After running a few tests... :~) I think I might be able to sort on the > inode...

Re: sort files by creation time

2005-12-12 Thread Todd W
"Brian Volk" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > After running a few tests... :~) I think I might be able to sort on the > inode... ? Does this make sense? > > my @files = glob("/mnt/qdls/MSDSIN/*"); > > foreach my $file (@files) { > >print "$file\n"; >my $ino =

RE: sort files by creation time

2005-12-12 Thread Wagner, David --- Senior Programmer Analyst --- WGO
Brian Volk wrote: > Hi All~ > > > > I'm using the glob function to grab all the files in a given > directory and then using crontab to check it every 5 minutes. Once I > have the files I'm using the diamond operator to read every line in > every file and *do something* if the line matches. He

RE: sort files by creation time

2005-12-12 Thread Brian Volk
-Original Message- From: Bob Showalter [mailto:[EMAIL PROTECTED] Sent: Monday, December 12, 2005 4:44 PM To: Brian Volk Cc: 'beginners@perl.org' Subject: Re: sort files by creation time Brian Volk wrote: > Hi All~ > > > > I'm using the glob function to

Re: sort files by creation time

2005-12-12 Thread Brian Volk
Todd W wrote: "Brian Volk" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] After running a few tests... :~) I think I might be able to sort on the inode... ? Does this make sense? my @files = glob("/mnt/qdls/MSDSIN/*"); foreach my $file (@files) { print "$file\n"; my $in

Re: sort files by creation time

2005-12-13 Thread Bob Showalter
Brian Volk wrote: Of course I have one more rookie question and a reference to a perldoc is just fine. :~) If I use the following code, why do I not need to declare the $a and the $b w/ my? Correct. This is explained in perldoc perlvar: $a $b Special package variables when using sor

RE: sort files by creation time

2005-12-13 Thread Brian Volk
-Original Message- From: Brian Volk Sent: Tuesday, December 13, 2005 8:10 AM To: 'Brian Franco' Subject: RE: sort files by creation time -Original Message- From: Brian Franco [mailto:[EMAIL PROTECTED] Sent: Monday, December 12, 2005 7:34 PM To: Brian Volk Subject

Re: sort files by creation time

2005-12-13 Thread OXx
Hello all, I try to launch my perl application as a windows service. I compile it with PAR so I have mysoft.exe Then i installed win32::daemon, no problem. I try this script so: use Win32::Daemon; %Hash = ( machine => '', name=> 'PerlTest', display => 'Oh m

Re: sort files by creation time

2005-12-13 Thread JupiterHost.Net
x27;', description => 'First prog as service', parameters =>'', ); if( Win32::Daemon::CreateService( \%Hash ) ) { print "Successfully added.\n"; } else { print "Failed to add service: " . Win32::FormatMessage

Re: sort files by creation time

2005-12-14 Thread Randal L. Schwartz
> "Todd" == Todd W <[EMAIL PROTECTED]> writes: Todd> my @files = map $_->[0], Todd> sort { $b->[1] <=> $a->[1] } Todd> map [ $_, -M ], Todd> grep -f, # get only plain files Todd> glob("/mnt/qdls/MSDSIN/*"); Since the map can also serve as a grep, and we can

Re: sort files by creation time

2005-12-14 Thread Jeff Pang
and we can use the _ handle to avoid stat'ing twice. Sorry,I don't know what is _ handle.Who help explain with it please,thanks. -Original Message- From: "Randal L. Schwartz" Sent: Dec 14, 2005 11:56 PM To: beginners@perl.org Subject: Re: sort files by creati

Re: sort files by creation time

2005-12-14 Thread Randal L. Schwartz
> "Jeff" == Jeff Pang <[EMAIL PROTECTED]> writes: Jeff> and we can use the _ handle to avoid stat'ing twice. Jeff> Sorry,I don't know what is _ handle.Who help explain with it please,thanks. It's documented. I refuse to retype the docs for a thing. :) -- Randal L. Schwartz - Stonehenge Co

Re: sort files by creation time

2005-12-15 Thread Bob Showalter
Randal L. Schwartz wrote: "Jeff" == Jeff Pang <[EMAIL PROTECTED]> writes: Jeff> and we can use the _ handle to avoid stat'ing twice. Jeff> Sorry,I don't know what is _ handle.Who help explain with it please,thanks. It's documented. I refuse to retype the docs for a thing. :) Specifically