{"id":29093131,"url":"https://github.com/joy1024/shell","last_synced_at":"2025-07-21T09:33:23.110Z","repository":{"id":301652598,"uuid":"990986021","full_name":"Joy1024/shell","owner":"Joy1024","description":"Linux平台常用脚本（清理）","archived":false,"fork":false,"pushed_at":"2025-06-28T01:52:18.000Z","size":1,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-28T02:31:07.725Z","etag":null,"topics":["clean","shell","shell-scripts","system-cleaner"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Joy1024.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-27T00:40:06.000Z","updated_at":"2025-06-28T01:52:21.000Z","dependencies_parsed_at":"2025-06-28T02:31:11.675Z","dependency_job_id":"5f38d40a-30f9-448a-8f91-be57ab125ac7","html_url":"https://github.com/Joy1024/shell","commit_stats":null,"previous_names":["joy1024/shell"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Joy1024/shell","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joy1024%2Fshell","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joy1024%2Fshell/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joy1024%2Fshell/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joy1024%2Fshell/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Joy1024","download_url":"https://codeload.github.com/Joy1024/shell/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joy1024%2Fshell/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266276133,"owners_count":23903981,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["clean","shell","shell-scripts","system-cleaner"],"created_at":"2025-06-28T08:06:08.355Z","updated_at":"2025-07-21T09:33:23.105Z","avatar_url":"https://github.com/Joy1024.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# shell.sh - Linux系统清理脚本\n## 使用方法：\n\n1. 将此脚本保存为 clean.sh\n2. 给予执行权限：chmod +x clean.sh\n3. 以 root 用户运行：sudo ./clean.sh \u003cusername\u003e\n4. 将此脚本添加到 crontab 定时任务中\n```\n执行`crontab -e`添加以下行以每天17点执行清理任务\n0 17 * * * /clean.sh \u003cusername\u003e  # 每天下午5点执行\n```\n## 输出效果如下:\n```\n2025-06-28 09:27:17 - Cleaning up for user: gaojie\n2025-06-28 09:27:17 - 当前系统发行版: ubuntu\n2025-06-28 09:27:17 - 🧹 清理系统日志...\nVacuuming done, freed 0B of archived journals from /run/log/journal/919cd5c32b7546c28789113fa3342de1.\nVacuuming done, freed 0B of archived journals from /run/log/journal.\n2025-06-28 09:27:17 - ✅ 系统日志已清理\n2025-06-28 09:27:17 - 🧹 清理临时文件...\n2025-06-28 09:27:17 - ✅ 临时文件已清理\n2025-06-28 09:27:17 - 🧹 清理开发相关的缓存...\n2025-06-28 09:27:17 - ✅ APT 缓存已清理\n2025-06-28 09:27:17 - 🧹 清理 Python pip 缓存...\nWARNING: No matching packages\nFiles removed: 0\n2025-06-28 09:27:17 - ✅ pip 缓存已清理\n2025-06-28 09:27:17 - 🧹 清理 Node.js npm 缓存...\nnpm warn using --force Recommended protections disabled.\n2025-06-28 09:27:17 - ✅ npm 缓存已清理\n2025-06-28 09:27:17 - 🧹 清理 Yarn\u0026Cypress 缓存...\n2025-06-28 09:27:17 - ✅ Yarn\u0026Cypress 缓存已清理\n2025-06-28 09:27:17 - 🧹 清理 VSCode 缓存...\n2025-06-28 09:27:17 - ✅ VSCode 缓存已清理\n2025-06-28 09:27:17 - 🧹 清理 GDB 缓存...\n2025-06-28 09:27:17 - ✅ GDB 缓存已清理\n2025-06-28 09:27:17 - 🧹 清理 Jetbrians 缓存...\n2025-06-28 09:27:17 - ✅ JetBrains 缓存已清理\n2025-06-28 09:27:17 - 🧹 清理 Google 浏览器缓存...\n2025-06-28 09:27:17 - ✅ Google 缓存已清理\n2025-06-28 09:27:18 - 🧹 清理 microsoft-edge 缓存...\n2025-06-28 09:27:18 - ✅ Microsoft Edge 缓存已清理\n2025-06-28 09:27:18 - ✅ 清理完成！\n2025-06-28 09:27:18 - 💾 清理后磁盘使用情况：\n/dev/mapper/vgkubuntu-root  467G  289G  154G  66% /\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoy1024%2Fshell","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjoy1024%2Fshell","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoy1024%2Fshell/lists"}