Commit 66b4c656 authored by Rémy Coutable's avatar Rémy Coutable

Clean up assets that are older than 4 days to reduce assets cache size

Signed-off-by: default avatarRémy Coutable <remy@rymai.me>
parent 1ca42413
#!/bin/bash
# Clean up cached files that are older than 1 week
find tmp/cache/assets/sprockets/ -type f -mtime +7 -execdir rm -- "{}" \;
# Clean up cached files that are older than 4 days
find tmp/cache/assets/sprockets/ -type f -mtime +4 -execdir rm -- "{}" \;
du -d 0 -h tmp/cache/assets/sprockets | cut -f1 | xargs -I % echo "tmp/cache/assets/sprockets/ is currently %"
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment