Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
find /path/to/files/* -mtime +1 -delete
At the same time, the nuance
-mtime +1
modified more than 1 day ago
-mtime 1
modified one day ago (today and the day before yesterday will not be affected)
instead of -delete, you can not write anything for a start, it will display what it finds on the screen to make sure everything is ok.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question