How do I delete a 1 year old file in Linux?

Trang Esther

New member
How do I delete a 1 year old file in Linux?
Answer
  1. find /path/to/files -type f -mtime +365 -delete would be easier. – …
  2. -delete isn’t in my aix find so I’m not accustomed to using it. …
  3. find … – …
  4. Also, it’s a good idea to use — in case the first file name begins with a – (although you can guarantee it won’t happen if the directory passed to find doesn’t begin with a – ). –
 

Tìm kiếm

Back
Top