I would like to make it so that the contents of the documents and desktop folder of a standard user account on a Mac gets deleted everyday at say, midnight. How can I make this happen?
The agent will be loaded after logging out and back in, or after running
Another option would be to add something like this to your crontab:
(You could save that as
It should be fairly simple with a cron job calling a shell script that deletes the contents of the specified directories
I don't have a Mac but I believe Macs come with a BASH-compatible shell. So something like this:
I'm not sure whether the Mac shell uses the classic *nix file path schema (/blah/blah) or the schema used by the Finder (blah:blah); that's something you can look into. The