![]() Just send the unnecessary junk to your trash folder and forget about them. Autotrash will take care of the trashed files. The above command will only process currently logged-in user's trash directory. If you want to make autotrash to process trash directories of all users (not just in your home directory), use -t option like below. $ autotrash -td 30Īutotrash also allows you to delete trashed files based on the space left or available on the trash file system.įor example, have a look at the following example. $ autotrash -max-free 1024 -d 30Īs per the above command, autotrash will only purge trashed files that are older than 30 days from the trash if there is less than 1GB of space left on the trash filesystem. This can be useful if your trash filesystem is running out of the space. We can also purge files from trash, oldest first, till there is at least 1GB of space on the trash filesystem. In this case, there is no restriction on how old trashed files are. You can combine both options ( -min-free and -max-free) in a single command like below. ![]() $ autotrash -max-free 2048 -min-free 1024 -d 30Īs per the above command, autotrash will start reading the trash if there is less than 2GB of free space, then start keeping an eye on. ![]() Autotrash callable only on entities free#Īt that point, remove files older than 30 days and if there is less than 1GB of free space after that remove even newer files.Īs you can see, all command should be manually run by the user. You might wonder, how can I automate this task? That's easy! Just add autotrash as crontab entry. Now, the commands will automatically run at a scheduled time and purge the files in your trash depending on the defined options. Autotrash callable only on entities free#.Autotrash callable only on entities install#.
0 Comments
Leave a Reply. |