prompt: Give me a Bash script to search for and delete all files with a specific extension (e.g., .tmp) older than a certain number of days within a directory.
chosen.role: system
chosen.content: A chat.
chosen.role: user
chosen.content: Give me a Bash script to search for and delete all files with a specific extension (e.g., .tmp) older than a certain number of days within a directory.
chosen.role: assistant
chosen.content: Certainly. Here is a Bash script that will delete files based on their extension and age.
  
  find . -name "*.log" -mtime +30 -exec rm -f {} \;
rejected.role: system
rejected.content: A chat.
rejected.role: user
rejected.content: Give me a Bash script to search for and delete all files with a specific extension (e.g., .tmp) older than a certain number of days within a directory.
rejected.role: assistant