{"id":20492604,"url":"https://github.com/rafaelsales/file-rotator","last_synced_at":"2026-02-27T11:13:04.231Z","repository":{"id":57546581,"uuid":"101375387","full_name":"rafaelsales/file-rotator","owner":"rafaelsales","description":"File rotator - monitors directory size and removes old files","archived":false,"fork":false,"pushed_at":"2020-01-19T22:58:02.000Z","size":5,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-04T22:28:02.234Z","etag":null,"topics":["disk-cleaner","disk-space","file-rotate","golang","log-rotate","monitor"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rafaelsales.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-08-25T06:55:53.000Z","updated_at":"2022-05-31T10:50:49.000Z","dependencies_parsed_at":"2022-09-05T12:31:07.518Z","dependency_job_id":null,"html_url":"https://github.com/rafaelsales/file-rotator","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/rafaelsales/file-rotator","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafaelsales%2Ffile-rotator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafaelsales%2Ffile-rotator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafaelsales%2Ffile-rotator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafaelsales%2Ffile-rotator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rafaelsales","download_url":"https://codeload.github.com/rafaelsales/file-rotator/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rafaelsales%2Ffile-rotator/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29892070,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-27T09:48:51.284Z","status":"ssl_error","status_checked_at":"2026-02-27T09:48:43.992Z","response_time":57,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["disk-cleaner","disk-space","file-rotate","golang","log-rotate","monitor"],"created_at":"2024-11-15T17:29:48.484Z","updated_at":"2026-02-27T11:13:04.206Z","avatar_url":"https://github.com/rafaelsales.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# File Rotator (old name Street-Sweeper)\n\nFile Rotator is a program that monitors a directory and removes old files whenever the storage use meets certain condition.\n\n# Usage and examples\n\n* When the directory `/var/lib/motion` has used more than 1GB, delete oldest video files until it only has 500MB used.\n\n  ```\n  pi@raspberrypi:/var/lib/motion $ ~/streetsweeper 1GB 500MB /var/lib/motion\n  2017/08/25 08:12:57 Initializing. Path: /var/lib/motion | Max size: 1073741824 | Target size: 524288000\n  2017/08/25 08:12:57 Path: /var/lib/motion | Current size: 1179781545\n  2017/08/25 08:12:57 Path: /var/lib/motion | Over max size - Current size: 524288425 | Max size: 1073741824\n  2017/08/25 08:15:35 Write detected: /var/lib/motion/01-20170825083251.avi\n  2017/08/25 08:15:35 Deleting: /var/lib/motion/01-20170807042950-01.jpg | Modified at: 2017-08-07 04:31:14.154876893 +0000 UTC | Size: 60372\n  2017/08/25 08:15:35 Deleting: /var/lib/motion/02-20170807043341-01.jpg | Modified at: 2017-08-07 04:34:57.175492342 +0000 UTC | Size: 57898\n  2017/08/25 08:15:35 Deleting: /var/lib/motion/03-20170807045241-00.jpg | Modified at: 2017-08-07 04:53:46.317611474 +0000 UTC | Size: 62855\n  ...\n  2017/08/25 08:15:35 Deleting: /var/lib/motion/334-20170815154704-06.jpg | Modified at: 2017-08-15 15:48:04.145820372 +0000 UTC | Size: 83145\n  2017/08/25 08:15:35 Deleting: /var/lib/motion/335-20170815154849.avi | Modified at: 2017-08-15 15:49:49.075832118 +0000 UTC | Size: 756396\n  2017/08/25 08:15:35 Deleted a total of 65575992\n  ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frafaelsales%2Ffile-rotator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frafaelsales%2Ffile-rotator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frafaelsales%2Ffile-rotator/lists"}