Skip to content

Instantly share code, notes, and snippets.

@riskiwah
Last active September 20, 2022 15:48
Show Gist options
  • Save riskiwah/9696de0a9d267065dcabc3e750a13d07 to your computer and use it in GitHub Desktop.
Save riskiwah/9696de0a9d267065dcabc3e750a13d07 to your computer and use it in GitHub Desktop.
[Unit]
Description=Files Cleaner
[Service]
Type=oneshot
ExecStart=/bin/echo "lets clean!"
# Dry run
ExecStart=/usr/bin/find /home/tarjow/ -type f -mtime +6 -exec echo rm {} \;
[Unit]
Description=Files Cleaner
[Timer]
# Every minutes
OnCalendar=*:5/1
Persistent=true
#RandomizedDelaySec=1d
[Install]
WantedBy=timers.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment