Unix Shell - Re: Comment tester à la fois la présence d'un fichier et la date de sa cré

This is Interesting: Free IT Magazines  
Home > Archive > Unix Shell > June 2006 > Re: Comment tester à la fois la présence d'un fichier et la date de sa cré





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Re: Comment tester à la fois la présence d'un fichier et la date de sa cré
laurentschneider@yahoo.com

2006-06-20, 7:26 am

or maybe

find fichier -mtime 1 | grep fichier && echo OK

but this means file has been modified within 24 hours...

laurentschneider@yahoo.com wrote:[vbcol=seagreen]
> if PERL -e 'exit ! (-r "fichier" && (time-time%86400 =3D=3D
> ((stat(_))[9])-((stat(_))[9])%86400))'; then echo today and exist; fi
>
> OK?
>
> but [9] is modification time, not creation time
>
> base60 wrote:
et la[vbcol=seagreen]
ntinu[vbcol=seagreen]
ur 1).[vbcol=seagreen]
gramme s'arr=EAte[vbcol=seagreen]
date de[vbcol=seagreen]
a (date[vbcol=seagreen]
e le[vbcol=seagreen]
pas"[vbcol=seagreen]
mme s'arr=EAtefiExit[vbcol=seagreen]

Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com