On Nov 13, ZHAO, BING said:
opendir GOP, "SCRATCH/BACKUP" or die "cannot open directory
SCRATCH/BACKUP:$!";
my @smm=grep{($_ ne ".") && ($_ ne "..")} readdir GOP;
foreach (@smm){
my($dev, $ino, $mode, $nlink, $uid, $gid, $rdev, $size, $atime,
$mtime, $ctime, $blksize, $blocks) = stat
On Sun, 13 Nov 2005 17:36:39 -0800
"ZHAO, BING" <[EMAIL PROTECTED]> wrote:
opendir GOP, "SCRATCH/BACKUP" or die "cannot open directory SCRATCH/BACKUP:$!";
my @smm=grep{($_ ne ".") && ($_ ne "..")} readdir GOP;
foreach (@smm){
my($dev, $ino, $mode, $nlink, $uid, $gid, $rdev, $size, $atime,
opendir GOP, "SCRATCH/BACKUP" or die "cannot open directory SCRATCH/BACKUP:$!";
my @smm=grep{($_ ne ".") && ($_ ne "..")} readdir GOP;
foreach (@smm){
my($dev, $ino, $mode, $nlink, $uid, $gid, $rdev, $size, $atime,
$mtime, $ctime, $blksize, $blocks) = stat($_);
print $ctime;
}
cl
On 10/4/05, Jay Savage <[EMAIL PROTECTED]> wrote:
>
> > >
> > > I want this file not to grow more than 50KB.
> > > How can I go about it. I been stuck here.. this above script will not
> do
>
>
Thanks a lot for all that gyan. :)
Cheers,
Umesh
"Because it's up-side down".
"Why is that?"
"It makes replies harder to read."
"Why not?"
"Please don't top-post." - Sherm Pendley, Mac OS X Perl list
On 10/4/05, Stephen Kratzer <[EMAIL PROTECTED]> wrote:
> Chances are that the file size will never equal exactly 500 bytes. You cou
Chances are that the file size will never equal exactly 500 bytes. You could
use >= instead of eq, and it should work. Also, you don't have to close
STDERR before reopening it, and in cases where you want to do numeric
comparisons, use == instead of eq. Hope that helps a little. Also, it might
Hello List,
#!/usr/bin/perl
close(STDERR);
open(STDERR,">/tmp/test.log") or die " Can't do it!!";
for($i=0; $i <=30; $i++) {
print STDERR "print something in the file.\n";
($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks)
= stat(STDERR);
if ( $size eq '500' )
D]">news:ato5rr$24p$[EMAIL PROTECTED]...
> Hi,
>
> I am trying to get the size of the file using the stat function in Perl
> 5.6.0. The actual size of the file is greater than 5 GB on Mandrake Linux
> 8.2 (kernel 2.4) using ext2 filesystem. When I run the stat command, the
> valu
On Tue, Dec 17, 2002 at 03:44:45PM -0600, Adnan Olia wrote:
> I am trying to get the size of the file using the stat function in Perl
> 5.6.0. The actual size of the file is greater than 5 GB on Mandrake Linux
> 8.2 (kernel 2.4) using ext2 filesystem. When I run the stat command, the
&
PM
To: Dan Muey
Subject: Re: Large file in stat function
Thanks for you responseI have another file which is smaller in size have the same
properties as the large file work perfectly fine.
The small file permissions, user and group
-rw user01 root smallfile.0
The large file permissions,
Hi,
I am trying to get the size of the file using the stat function in Perl
5.6.0. The actual size of the file is greater than 5 GB on Mandrake Linux
8.2 (kernel 2.4) using ext2 filesystem. When I run the stat command, the
value of the size is 0, this is also true for all values of the stat
ate
print -A, "\n" if /^c/;
}
hth,
Maurice Reeves
buzzcutbuddha www.perlmonks.org
>From: COLLINEAU Franck FTRD/DMI/TAM
><[EMAIL PROTECTED]>
>To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
>Subject: Stat function
>Date: Mon, 10 Dec 2001
I have found
Thanks
-Message d'origine-
De : COLLINEAU Franck FTRD/DMI
[mailto:[EMAIL PROTECTED]]
Envoyé : lundi 10 décembre 2001 11:08
À : '[EMAIL PROTECTED]'
Objet : Stat function
Greetings,
I have the following code:
opendir (INFO,"l:/01_informatique&q
Greetings,
I have the following code:
opendir (INFO,"l:/01_informatique") || die " impossible d'ouvrire le
répertoire 01_informatique: $!";
while ($fic=readdir INFO)
{
if($fic=~/^c/)
{
@date=stat($fic);
print "$date[7]\n";
}
}
close INFO;
> -Original Message-
> From: COLLINEAU Franck FTRD/DMI/TAM
> [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, November 20, 2001 3:31 AM
> To: [EMAIL PROTECTED]
> Subject: Stat function
>
>
> Hi!
>
> I have the following code:
>
> #!/usr/bin/pe
Hi!
I have the following code:
#!/usr/bin/perl -w
open(FIC,">/home/collineau/Perl/Programmes/01_informatique/sauve/c0111_05.ht
m") || die "Impossible d'ouvrir $!\n";;
@tab = stat (FIC);
print scalar localtime($tab[10]);
The date of c0111_05.htm is november 5th 2001.
But the print is now !
Hi!
I have the following code:
#!/usr/bin/perl -w
open(FIC,">/home/collineau/Perl/Programmes/01_informatique/sauve/c0111_05.htm
")
|| die "Impossible d'ouvrir $!\n";;
@tab = stat (FIC);
print scalar localtime($tab[10]);
The date of c0111_05.htm is november 5th 2001.
But the print is now !
17 matches
Mail list logo