[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [cobalt-users] deleteing old files



man find

here are some interesting options (tip of the iceberg):
      -mmin n
              File's data was last modified n minutes ago.

       -mtime n
              File's data was last modified n*24 hours ago.

       -name pattern
              Base of file name (the path with the leading direc­
              tories removed) matches shell pattern pattern.  The
              metacharacters  (`*', `?', and `[]') do not match a
              `.' at the start of the base  name.   To  ignore  a
              directory  and  the files under it, use -prune; see
              an example in the description of -path.

       -newer file
              File was modified more recently than file.   -newer
              is affected by -follow only if -follow comes before
              -newer on the command line.


find . -type f --some_options | xargs rm



> -----Original Message-----
> From: cobalt-users-admin@xxxxxxxxxxxxxxx
> [mailto:cobalt-users-admin@xxxxxxxxxxxxxxx]On Behalf Of Thomas Hodkin
> Sent: Monday, January 14, 2002 12:29 PM
> To: Cobalt-Users (E-mail)
> Subject: [cobalt-users] deleteing old files
>
>
>  hi does anyone if there is a way to delete file out of a specified
> directory if they are older then  a required date
>
> thanks
>
> Tom Hodkin
> (Software applications Engineer)
> SEG Europe Ltd.
> Unit 1
> Willow court
> Bracewell Ave
> Poulton Le Fylde
> Lancashire
> FY6 8JF
>
> telephone:  01253 893688
> facsimile:   01253 899226
> mobile:      07973 321217
> email:        tom@xxxxxxxx
> web:          www.segeurope.net
>
> Registered in England  No.3072184
>
> Notice of Confidentiality:
> The email (and its attachment(s) if any) is intended for the named
> addressee(s) only.  It contains information which may be confidential
> and/or privileged and/or exempt from disclosure under applicable law.
>
> Unless you are the named addressee (or authorised to receive it for
> the addressee) you may not read, copy or use it, or disclose it to
> anyone else. Unauthorised use, copying or disclosure is strictly
> forbidden.
> prohibited and may be unlawful.
>
> If you have received this transmission in error please notify the
> sender by telephone immediately (+44(0)1253 893688) and delete the message
> from your email system.
>
>
>
>
> _______________________________________________
> cobalt-users mailing list
> cobalt-users@xxxxxxxxxxxxxxx
> To Subscribe or Unsubscribe, please go to:
> http://list.cobalt.com/mailman/listinfo/cobalt-users