In order to reduce disk space usage, I want to automate a temporary clean in my Downloads
folder. I figured two ways to do so:
1) Changing the configurations of firefox, etc. to save files to /tmp/
(this would require, for safety, changing the variable TMPTIME
in /etc/default/rcS
to 7 or more days);
2) Turning the ~/Downloads
folder into a temporary directory that behaves similarly to /tmp/
, deleting old files. The problem is that in /tmp
files are indiscriminately deleted in the end of the session; in ~/Downloads
folder it would be better to delete files by their creation date.
I'm not very sympathetic to the first option, since it requires a lot of config. I'd like some help to implement the second one. What's the best way to do it?