Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

ubuntu delete files older than 5 days

#this deletes all files in /path/to/directory/ older than 7 days
find /path/to/directory/ -type f -mtime +7 -execdir rm -- '{}' ;
 
PREVIOUS NEXT
Tagged: #ubuntu #delete #files #older #days
ADD COMMENT
Topic
Name
7+6 =