├── README.md ├── exclusions └── exclusions.json ├── systemcleaner_user_filter ├── com.android.bankabc_caches_public_storage.scuf.sdm.json ├── com.eg.android.AlipayGphone_caches_private_storage.scuf.sdm.json ├── com.eg.android.AlipayGphone_caches_public_storage.scuf.sdm.json ├── com.jingdong.app.mall_caches_private_storage.scuf.sdm.json ├── com.jingdong.app.mall_caches_public_storage.scuf.sdm.json ├── com.netease.cloudmusic_analytics_private_storage.scuf.sdm.json ├── com.netease.cloudmusic_bug_reporting_public_storage.scuf.sdm.json ├── com.netease.cloudmusic_cache_private_storage.scuf.sdm.json ├── com.netease.cloudmusic_cache_public_storage.scuf.sdm.json ├── com.seazon.feedme_caches_public_storage.scuf.sdm.json ├── com.suning.mobile.ebuy_caches_public_storage.scuf.sdm.json ├── com.taobao.idlefish_caches_public_storage.scuf.sdm.json ├── com.taobao.taobao_caches_private_storage.scuf.sdm.json ├── com.taobao.taobao_caches_public_storage.scuf.sdm.json ├── com.tencent.android.qqdownloader_caches_public_storage.scuf.sdm.json ├── com.tencent.mm_advertisement_public_storage.scuf.sdm.json ├── com.tencent.mm_caches_private_storage.scuf.sdm.json ├── com.tencent.mm_caches_public_storage.scuf.sdm.json ├── com.tencent.mm_chat_image_private_storage.scuf.sdm.json ├── com.tencent.mm_chat_image_public_storage.scuf.sdm.json ├── com.tencent.mm_chat_video_public_storage.scuf.sdm.json ├── com.tencent.mm_chat_voice_public_storage.scuf.sdm.json ├── com.tencent.mobileqq_caches_private_storage.scuf.sdm.json ├── com.tencent.mobileqq_caches_public_storage.scuf.sdm.json ├── com.tencent.mobileqq_chat_image_public_storage.scuf.sdm.json ├── com.tencent.mobileqq_chat_video_public_storage.scuf.sdm.json ├── com.tencent.mobileqq_chat_voice_public_storage.scuf.sdm.json ├── com.tencent.tim_caches_public_storage.scuf.sdm.json ├── com.tencent.tim_chat_image_public_storage.scuf.sdm.json ├── com.tencent.tim_chat_video_public_storage.scuf.sdm.json ├── com.tencent.tim_chat_voice_public_storage.scuf.sdm.json ├── com.zhihu.android_advertisement_private_storage.scuf.sdm.json ├── com.zhihu.android_cache_public_storage.scuf.sdm.json ├── general_bug_reporting_private_storage.scuf.sdm.json ├── general_bug_reporting_public_storage.scuf.sdm.json ├── general_webcache_private_storage.scuf.sdm.json └── obsolete.apk_public_storage.scuf.sdm.json └── tools └── tree.sh /README.md: -------------------------------------------------------------------------------- 1 | # SD Maid用户规则 2 | 3 | # 说明 4 | 5 | SD Maid是安卓上最强大的清理类应用,但它默认的规则没有很好地适配国内的应用。此项目创建的初衷就是适配国内的应用。 6 | 7 | 此规则 8 | 9 | * 免费使用,禁止任何商业用途。同步在QQ 群内分享。 10 | 11 | * 和官方规则一样,每条规则前都有颜色图标,范围从绿色到红色,代表规则内文件的重要性或者规则误删文件的可能性。 12 | 13 | * 支持存储空间隔离(存储重定向)。 14 | 15 | * 针对扫描机制优化。 16 | 17 | 1、**使用前请先阅读[wiki](https://github.com/redjumper/sdmaid-userfilter/wiki)和[怎么导出应用的文件路径列表来帮助本项目](https://github.com/redjumper/sdmaid-userfilter/issues/1)。** 18 | 19 | 2、为尊重作者的知识产权,不会采用再编译SD Maid,集成应用清理规则的方式。 20 | 21 | 3、master分支下的规则经过测试后才发布,一般不会误删文件,但本人不对规则可能导致的误删做任何承诺,如发现问题,可以提issue或者去QQ 群反馈。 22 | 23 | 4、SD Maid用户规则相关讨论 QQ 群: 945792668 TG 群: @sdmaid_userfilter 24 | 25 | # 使用方法 26 | 27 | 1、设置 28 | 29 | 参照[wiki](https://github.com/redjumper/sdmaid-userfilter/wiki/3.%E8%AE%BE%E7%BD%AE) 30 | 31 | 2、用户规则 32 | 33 | * 删除原规则 34 | 35 | 系统清理>右上角齿轮>用户,删除所有规则 36 | 37 | 如果设备已root,也可以直接删除/data/data/eu.thedarken.sdm/files/systemcleaner_user_filter/下所有文件 38 | 39 | * 导入新规则 40 | 41 | 系统清理>右上角齿轮>用户>右上角的下载图标,手动导入systemcleaner_user_filter下所有文件 42 | 43 | 如果设备已root,也可以直接复制systemcleaner_user_filter下所有文件到/data/data/eu.thedarken.sdm/files/systemcleaner_user_filter/ 44 | 45 | **注意:系统清理比较耗时,按需启用规则** 46 | 47 | 3、排除项 48 | 49 | 其他>排除项>右上角省略号>导入,手动导入exclusions下exclusions.json 50 | 51 | # 反馈 52 | 53 | 如果有疑问,请提issue或者去QQ/TG群反馈。 54 | -------------------------------------------------------------------------------- /exclusions/exclusions.json: -------------------------------------------------------------------------------- 1 | { 2 | "exclusions": [ 3 | { 4 | "contains_string": "/data/data/com.taobao.idlefish/files/DAI/Utlink/model", 5 | "tags": [ 6 | "SYSTEMCLEANER" 7 | ], 8 | "type": "SIMPLE_CONTAINS" 9 | }, 10 | { 11 | "contains_string": "/storage/emulated/0/Android/data/com.tencent.qqlive/files/.res64/56/", 12 | "tags": [ 13 | "SYSTEMCLEANER" 14 | ], 15 | "type": "SIMPLE_CONTAINS" 16 | } 17 | ], 18 | "version": 4 19 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.android.bankabc_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "中国农业银行 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.android.bankabc_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "/com.android.bankabc/files/image/", 10 | "/com.android.bankabc/files/nebulaDownload/downloads/", 11 | "/com.android.bankabc/image/" 12 | ], 13 | "locations": [ 14 | "PUBLIC_DATA", 15 | "SDCARD" 16 | ] 17 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.eg.android.AlipayGphone_caches_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "支付宝 缓存 (私有存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.eg.android.AlipayGphone_caches_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "mainPath": [ 10 | "/data/data/com.eg.android.AlipayGphone/app_alipay_msp_disk_cache/", 11 | "/data/data/com.eg.android.AlipayGphone/files/cashier_templates/", 12 | "/data/data/com.eg.android.AlipayGphone/files/ccdn/caches/packages/", 13 | "/data/data/com.eg.android.AlipayGphone/files/ccdn/caches/resources/" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.eg.android.AlipayGphone_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "支付宝 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.eg.android.AlipayGphone_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "/com.eg.android.AlipayGphone/files/", 10 | "/alipay/" 11 | ], 12 | "regexes": [ 13 | "^(?:.+?)(?>com\\.eg\\.android\\.AlipayGphone/files/multimedia/[0-9a-z]{32}/[0-9a-z]{2}/)(?:.+)$", 14 | "^(?:.+?)(?>alipay/com\\.eg\\.android\\.AlipayGphone/nebulaDownload/downloads/)(?:.+)$", 15 | "^(?:.+?)(?>alipay/com\\.eg\\.android\\.AlipayGphone/openplatform/downloads/)(?:.+)$", 16 | "^(?:.+?)(?>alipay/multimedia/[0-9a-z]{32}/[0-9a-z]{2}/)(?:.+)$" 17 | ], 18 | "locations": [ 19 | "PUBLIC_DATA", 20 | "SDCARD" 21 | ] 22 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.jingdong.app.mall_caches_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "京东 缓存 (私有存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.jingdong.app.mall_caches_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "mainPath": [ 10 | "/data/data/com.jingdong.app.mall/files/custom_theme_pics/", 11 | "/data/data/com.jingdong.app.mall/files/jingdongbannerBgVideo/", 12 | "/data/data/com.jingdong.app.mall/files/jingdonghomeSkuVideo/", 13 | "/data/data/com.jingdong.app.mall/files/start_image/" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.jingdong.app.mall_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "京东 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.jingdong.app.mall_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.jingdong.app.mall/files/image/", 10 | "/JDIM/cache/image/" 11 | ], 12 | "exclusions": [ 13 | ".nomedia" 14 | ], 15 | "locations": [ 16 | "PUBLIC_DATA", 17 | "SDCARD" 18 | ] 19 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.netease.cloudmusic_analytics_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "网易云音乐 分析 (私有存储)", 4 | "description": "分析相关文件", 5 | "identifier": "com.netease.cloudmusic_analytics_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "mainPath": [ 9 | "/data/data/com.netease.cloudmusic/files/MAMStatistic/", 10 | "/data/data/com.netease.cloudmusic/files/MAMStatisticV2/", 11 | "/data/data/com.netease.cloudmusic/files/RealTimeStatistic/", 12 | "/data/data/com.netease.cloudmusic/files/Statistic/", 13 | "/data/data/com.netease.cloudmusic/files/StatisticV2/" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.netease.cloudmusic_bug_reporting_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "网易云音乐 Bug 反馈 (公共存储)", 4 | "description": "与 bug 报告相关的文件", 5 | "identifier": "com.netease.cloudmusic_bug_reporting_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "pathContains": [ 9 | "/netease/cloudmusic/Stacktrace/" 10 | ], 11 | "locations": [ 12 | "PUBLIC_DATA", 13 | "SDCARD" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.netease.cloudmusic_cache_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "网易云音乐 缓存 (私有存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.netease.cloudmusic_cache_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "mainPath": [ 10 | "/data/data/com.netease.cloudmusic/files/NetworkCache/", 11 | "/data/data/com.netease.cloudmusic/files/sailfish/" 12 | ] 13 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.netease.cloudmusic_cache_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "网易云音乐 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.netease.cloudmusic_cache_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "pathContains": [ 10 | "/netease/cloudmusic/" 11 | ], 12 | "regexes": [ 13 | "^(?:.+?)(?>/netease/cloudmusic/Cache/(?!ImageCache)\\w+\/)(?:.+)$", 14 | "^(?:.+?)(?>/netease/cloudmusic/Cache/ImageCache/v2\\.ols100\\.1/)(?:.+)$" 15 | ], 16 | "locations": [ 17 | "PUBLIC_DATA", 18 | "SDCARD" 19 | ] 20 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.seazon.feedme_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "FeedMe 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.seazon.feedme_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.seazon.feedme/files/providers/Feedly/cache/", 10 | "com.seazon.feedme/files/providers/Feedly/states/" 11 | ], 12 | "locations": [ 13 | "PUBLIC_DATA" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.suning.mobile.ebuy_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "苏宁易购 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.suning.mobile.ebuy_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.suning.mobile.ebuy/files/Pictures/cache/", 10 | "/oneplayer/.local/" 11 | ], 12 | "locations": [ 13 | "PUBLIC_DATA", 14 | "SDCARD" 15 | ] 16 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.taobao.idlefish_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "闲鱼 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.taobao.idlefish_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.taobao.idlefish/files/AVFSCache/" 10 | ], 11 | "regexes": [ 12 | "^(?:.+?)(?>/com\\.taobao\\.idlefish/files/AVFSCache/.+?/files/v2\\.ols100\\.1/)(?:.+)$" 13 | ], 14 | "locations": [ 15 | "PUBLIC_DATA" 16 | ] 17 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.taobao.taobao_caches_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "淘宝 缓存 (私有存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.taobao.taobao_caches_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "pathContains": [ 10 | "/data/data/com.taobao.taobao/" 11 | ], 12 | "regexes": [ 13 | "^(?>/data/data/com\\.taobao\\.taobao/app_zcache/apps/[a-z]+_taobao_[0-9]+/)(?:.+)$", 14 | "^(?>/data/data/com\\.taobao\\.taobao/files/AVFSCache/.+?/files/v2\\.ols100\\.1/)(?:.+)$" 15 | ] 16 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.taobao.taobao_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "淘宝 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.taobao.taobao_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.taobao.taobao/files/AVFSCache/" 10 | ], 11 | "regexes": [ 12 | "^(?:.+?)(?>/com\\.taobao\\.taobao/files/AVFSCache/.+?/files/v2\\.ols100\\.1/)(?:.+)$" 13 | ], 14 | "locations": [ 15 | "PUBLIC_DATA" 16 | ] 17 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.android.qqdownloader_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "应用宝 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.tencent.android.qqdownloader_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.tencent.android.qqdownloader/" 10 | ], 11 | "exclusions": [ 12 | ".nomedia" 13 | ], 14 | "regexes": [ 15 | "^(?:.+?)(?>com\\.tencent\\.android\\.qqdownloader/files/tassistant/apk/)[\\w\\.]+\\.apk(?:.+)$", 16 | "^(?:.+?)(?>com\\.tencent\\.android\\.qqdownloader/files/tassistant/gif/)(?:.+)$", 17 | "^(?:.+?)(?>com\\.tencent\\.android\\.qqdownloader/files/tassistant/mediaCache/)(?:.+)$", 18 | "^(?:.+?)(?>com\\.tencent\\.android\\.qqdownloader/files/tassistant/pic/)(?:.+)$", 19 | "^(?:.+?)(?>com\\.tencent\\.android\\.qqdownloader/files/tassistant/video/)(?:.+)$" 20 | ], 21 | "locations": [ 22 | "PUBLIC_DATA" 23 | ] 24 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mm_advertisement_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "微信 广告 (公共存储)", 4 | "description": "超过 14 天的广告", 5 | "identifier": "com.tencent.mm_advertisement_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "/com.tencent.mm/MicroMsg/hbstoryvideo/", 10 | "/com.tencent.mm/MicroMsg/sns_ad_landingpages/" 11 | ], 12 | "exclusions": [ 13 | ".nomedia" 14 | ], 15 | "locations": [ 16 | "PUBLIC_DATA" 17 | ] 18 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mm_caches_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "微信 缓存 (私有存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.tencent.mm_caches_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "pathContains": [ 10 | "/data/data/com.tencent.mm/MicroMsg/" 11 | ], 12 | "regexes": [ 13 | "^(?>/data/data/com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/cdn/download/)(?:.+)$", 14 | "^(?>/data/data/com\\.tencent\\.mm/MicroMsg/emoji/cover/)(?:.+)$", 15 | "^(?>/data/data/com\\.tencent\\.mm/MicroMsg/mmslot/webcached/\\d+/\\d+/)(?:.+)$", 16 | "^(?>/data/data/com\\.tencent\\.mm/MicroMsg/tmp/)(?:.+)$" 17 | ] 18 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mm_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "微信 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.tencent.mm_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.tencent.mm/MicroMsg/" 10 | ], 11 | "regexes": [ 12 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/attachment/)(?:.+)$", 13 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/bizimg/)(?:.+)$", 14 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/brandicon/)(?:.+)$", 15 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/favoffline/)(?:.+)$", 16 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/favorite/)(?:.+)$", 17 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/image/)(?:.+)$", 18 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/openapi/)(?:.+)$", 19 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/openapi_cache/)(?:.+)$", 20 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/openim/)(?:.+)$", 21 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/recbiz/)(?:.+)$", 22 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/record/)(?:.+)$", 23 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/scanner/)(?:.+)$", 24 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/sns/)(?:.+)$", 25 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/\\.tmp/)(?:.+)$", 26 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/Cache/)(?:.+)$", 27 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/card/)(?:.+)$", 28 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/CDNTemp/)(?:.+)$", 29 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/FailMsgFileCache/)(?:.+)$", 30 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/wallet/)(?:.+)$", 31 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/wallet_images/)(?:.+)$", 32 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/wxacache/)(?:.+)$", 33 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/wxafiles/)(?:.+)$", 34 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/wxanewfiles/)(?:.+)$", 35 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/wxvideocache/)(?:.+)$", 36 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/wxvideotmp/)(?:.+)$" 37 | ], 38 | "locations": [ 39 | "PUBLIC_DATA" 40 | ] 41 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mm_chat_image_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "微信 聊天图片 (私有存储)", 4 | "description": "超过 14 天的聊天图片", 5 | "identifier": "com.tencent.mm_chat_image_private_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "pathContains": [ 10 | "/data/data/com.tencent.mm/MicroMsg/" 11 | ], 12 | "exclusions": [ 13 | ".nomedia" 14 | ], 15 | "regexes": [ 16 | "^(?>/data/data/com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/image2/)(?:.+)$" 17 | ] 18 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mm_chat_image_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "微信 聊天图片 (公共存储)", 4 | "description": "超过 14 天的聊天图片", 5 | "identifier": "com.tencent.mm_chat_image_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.tencent.mm/MicroMsg/" 10 | ], 11 | "exclusions": [ 12 | ".nomedia" 13 | ], 14 | "regexes": [ 15 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/image2/)(?:.+)$" 16 | ], 17 | "locations": [ 18 | "PUBLIC_DATA" 19 | ] 20 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mm_chat_video_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "微信 聊天视频 (公共存储)", 4 | "description": "超过 14 天的聊天视频", 5 | "identifier": "com.tencent.mm_chat_video_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.tencent.mm/MicroMsg/" 10 | ], 11 | "regexes": [ 12 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/video/)(?:.+)$" 13 | ], 14 | "locations": [ 15 | "PUBLIC_DATA" 16 | ] 17 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mm_chat_voice_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "微信 聊天语音 (公共存储)", 4 | "description": "超过 14 天的聊天语音", 5 | "identifier": "com.tencent.mm_chat_voice_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.tencent.mm/MicroMsg/" 10 | ], 11 | "exclusions": [ 12 | ".nomedia" 13 | ], 14 | "regexes": [ 15 | "^(?:.+?)(?>com\\.tencent\\.mm/MicroMsg/[0-9a-z]{32}/voice2/)(?:.+)$" 16 | ], 17 | "locations": [ 18 | "PUBLIC_DATA" 19 | ] 20 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mobileqq_caches_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "QQ 缓存 (私有存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.tencent.mobileqq_caches_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "pathContains": [ 10 | "/data/data/com.tencent.mobileqq/files/.info/", 11 | "/data/data/com.tencent.mobileqq/files/ArkApp/Cache/", 12 | "/data/data/com.tencent.mobileqq/files/ArkApp_qzone/Cache/", 13 | "/data/data/com.tencent.mobileqq/files/ArkApp_tool/Cache/", 14 | "/data/data/com.tencent.mobileqq/files/far/", 15 | "/data/data/com.tencent.mobileqq/files/fdmon/", 16 | "/data/data/com.tencent.mobileqq/files/gvideo/", 17 | "/data/data/com.tencent.mobileqq/files/pddata/app/offline/", 18 | "/data/data/com.tencent.mobileqq/files/ShadowPlugin_ilive-pluginapngCache/", 19 | "/data/data/com.tencent.mobileqq/files/tempFile", 20 | "/data/data/com.tencent.mobileqq/files/WebOfflineRes/" 21 | ] 22 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mobileqq_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "QQ 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.tencent.mobileqq_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.tencent.mobileqq/" 10 | ], 11 | "exclusions": [ 12 | ".nomedia" 13 | ], 14 | "regexes": [ 15 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/files/\\.info/)(?:.+)$", 16 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/files/ae/camera/capture/)(?:.+)$", 17 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/files/opensdk_tmp/)(?:.+)$", 18 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/files/QWallet/\\.tmp/)(?:.+)$", 19 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/files/tbs/TbsReaderTemp/)(?:.+)$", 20 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/files/tencent/MobileQQ/\\.pendant/)(?:.+)$", 21 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/files/uploader/)(?:.+)$", 22 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/qzone/)(?:.+)$", 23 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/mini/files/)(?:.+)$", 24 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/\\.emotionsm/)(?:.+)$", 25 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/\\.gift/)(?:.+)$", 26 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/pddata/app/offline/)(?:.+)$", 27 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/photo/)(?:.+)$", 28 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/Scribble/ScribbleCache/)(?:.+)$", 29 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/shortvideo/)(?:.+)$", 30 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/tencent/MobileQQ/webso/offline/)(?:.+)$", 31 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/MobileQQ/thumb/)(?:.+)$", 32 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/QQfile_recv/\\.)(?:.+)$", 33 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/Qzone/.AppCenterImgCache/)(?:.+)$", 34 | "^(?:.+?)(?>com\\.tencent\\.mobileqq/Tencent/TMAssistantSDK/Download/com.tencent.mobileqq/)(?:.+)$" 35 | ], 36 | "locations": [ 37 | "PUBLIC_DATA" 38 | ] 39 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mobileqq_chat_image_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "QQ 聊天图片 (公共存储)", 4 | "description": "超过 14 天的聊天图片", 5 | "identifier": "com.tencent.mobileqq_chat_image_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "encent/MobileQQ/chatpic/" 10 | ], 11 | "locations": [ 12 | "PUBLIC_DATA", 13 | "SDCARD" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mobileqq_chat_video_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "QQ 聊天拍摄短视频 (公共存储)", 4 | "description": "超过 14 天的聊天拍摄短视频", 5 | "identifier": "com.tencent.mobileqq_chat_video_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "encent/MobileQQ/shortvideo/" 10 | ], 11 | "exclusions": [ 12 | "thumbs/.nomedia" 13 | ], 14 | "locations": [ 15 | "PUBLIC_DATA", 16 | "SDCARD" 17 | ] 18 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.mobileqq_chat_voice_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "QQ 聊天语音 (公共存储)", 4 | "description": "超过 14 天的聊天语音", 5 | "identifier": "com.tencent.mobileqq_chat_voice_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "encent/MobileQQ/" 10 | ], 11 | "regexes": [ 12 | "^(?:.+?)(?>T|tencent/MobileQQ/[\\d]+/ptt/)(?:.+)$" 13 | ], 14 | "locations": [ 15 | "PUBLIC_DATA", 16 | "SDCARD" 17 | ] 18 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.tim_caches_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "TIM 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.tencent.tim_caches_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.tencent.tim/", 10 | "encent/mini/files/", 11 | "encent/Tim/" 12 | ], 13 | "exclusions": [ 14 | ".nomedia" 15 | ], 16 | "regexes": [ 17 | "^(?:.+?)(?>com\\.tencent\\.tim/files/\\.info/)(?:.+)$", 18 | "^(?:.+?)(?>com\\.tencent\\.tim/qzone/)(?:.+)$", 19 | "^(?:.+?)(?>T|tencent/mini/files/)(?:.+)$", 20 | "^(?:.+?)(?>T|tencent/Tim/\\.emotionsm/)(?:.+)$", 21 | "^(?:.+?)(?>T|tencent/Tim/ArkApp/Cache/)(?:.+)$", 22 | "^(?:.+?)(?>T|tencent/Tim/photo/)(?:.+)$", 23 | "^(?:.+?)(?>T|tencent/Tim/thumb/)(?:.+)$", 24 | "^(?:.+?)(?>T|tencent/Timfile_recv/\\.)(?:.+)$", 25 | "^(?:.+?)(?>T|tencent/TMAssistantSDK/Download/com\\.tencent\\.tim/)(?:.+)$" 26 | ], 27 | "locations": [ 28 | "PUBLIC_DATA", 29 | "SDCARD" 30 | ] 31 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.tim_chat_image_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "TIM 聊天图片 (公共存储)", 4 | "description": "超过 14 天的聊天图片", 5 | "identifier": "com.tencent.tim_chat_image_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "encent/Tim/diskcache/" 10 | ], 11 | "locations": [ 12 | "PUBLIC_DATA", 13 | "SDCARD" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.tim_chat_video_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "TIM 聊天拍摄短视频 (公共存储)", 4 | "description": "超过 14 天的聊天拍摄短视频", 5 | "identifier": "com.tencent.tim_chat_video_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "encent/Tim/shortvideo/" 10 | ], 11 | "exclusions": [ 12 | "thumbs/.nomedia" 13 | ], 14 | "locations": [ 15 | "PUBLIC_DATA", 16 | "SDCARD" 17 | ] 18 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.tencent.tim_chat_voice_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "TIM 聊天语音 (公共存储)", 4 | "description": "超过 14 天的聊天语音", 5 | "identifier": "com.tencent.tim_chat_voice_public_storage.scuf.sdm", 6 | "color": "#FFFF5722", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "encent/Tim/" 10 | ], 11 | "regexes": [ 12 | "^(?:.+?)(?>T|tencent/Tim/[\\d]+/ptt/)(?:.+)$" 13 | ], 14 | "locations": [ 15 | "PUBLIC_DATA", 16 | "SDCARD" 17 | ] 18 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.zhihu.android_advertisement_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "知乎 广告 (私有存储)", 4 | "description": "超过 14 天的广告", 5 | "identifier": "com.zhihu.android_advertisement_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "mainPath": [ 10 | "/data/data/com.zhihu.android/" 11 | ], 12 | "regexes": [ 13 | "^(?>/data/data/com\\.zhihu\\.android/files/[A-Za-z0-9]+)/[A-Za-z0-9]+.mp4$", 14 | "^(?>/data/data/com\\.zhihu\\.android/files/IFlyAdImgCache/)(?:.+)$" 15 | ] 16 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/com.zhihu.android_cache_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "知乎 缓存 (公共存储)", 4 | "description": "超过 14 天的缓存", 5 | "identifier": "com.zhihu.android_cache_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "minimumAge": 1209600000, 8 | "pathContains": [ 9 | "com.zhihu.android/files/Movies/VideoCache/", 10 | "com.zhihu.android/files/Pictures/" 11 | ], 12 | "locations": [ 13 | "PUBLIC_DATA" 14 | ] 15 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/general_bug_reporting_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "通用 Bug 反馈 (私有存储)", 4 | "description": "与 bug 报告相关的文件", 5 | "identifier": "general_bug_reporting_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "pathContains": [ 10 | "Log/", 11 | "/xlog/", 12 | "/app_tombs/", 13 | ".mmap", 14 | "/app_bugly/", 15 | "/log/", 16 | "/logs/", 17 | "/app_log/", 18 | "/applog/", 19 | "/.log/", 20 | "/app_logs/", 21 | "/debug_log/", 22 | "/Logs/" 23 | ], 24 | "locations": [ 25 | "PRIVATE_DATA" 26 | ] 27 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/general_bug_reporting_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "通用 Bug 反馈 (公共存储)", 4 | "description": "与 bug 报告相关的文件", 5 | "identifier": "general_bug_reporting_public_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "pathContains": [ 8 | "logs/", 9 | "log/", 10 | "Log/", 11 | "/Logs/", 12 | "/applogic/", 13 | "crash/", 14 | "wtlogin/", 15 | ".tlog", 16 | "/trafficLogic/", 17 | "logcatic/", 18 | "Log.txt" 19 | ], 20 | "locations": [ 21 | "PUBLIC_DATA", 22 | "SDCARD" 23 | ] 24 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/general_webcache_private_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "WebView 缓存 (私有存储)", 4 | "description": "应用内置浏览器的缓存", 5 | "identifier": "general_webcache_private_storage.scuf.sdm", 6 | "color": "#FF4CAF50", 7 | "rootOnly": true, 8 | "minimumAge": 1209600000, 9 | "pathContains": [ 10 | "webview", 11 | "app_xwalk" 12 | ], 13 | "regexes": [ 14 | "^(?:.+?)(?>webview.*?\/(?:GPU|Script)?Cache(?:Storage)?\/)(?:.+)$", 15 | "^(?:.+?)(?>app_xwalk.*?\/(?:GPU|Script)?Cache(?:Storage)?\/)(?:.+)$" 16 | ], 17 | "locations": [ 18 | "PRIVATE_DATA" 19 | ] 20 | } -------------------------------------------------------------------------------- /systemcleaner_user_filter/obsolete.apk_public_storage.scuf.sdm.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": 4, 3 | "label": "过时的APK文件 (公共存储)", 4 | "description": "公共存储中已下载的应用安装文件,已安装该应用的更新版本。", 5 | "identifier": "obsolete.apk_public_storage.scuf.sdm", 6 | "color": "#FFFFEB3B", 7 | "targetType": "FILE", 8 | "possibleNameEndings": [ 9 | ".apk" 10 | ], 11 | "locations": [ 12 | "PUBLIC_DATA", 13 | "SDCARD" 14 | ] 15 | } -------------------------------------------------------------------------------- /tools/tree.sh: -------------------------------------------------------------------------------- 1 | #!/system/bin/sh 2 | 3 | echo "导出文件列表的时间可能会有点长,请耐心等待,中途不要停止脚本,导出完成会有提示" 4 | 5 | start_time=`date +%s` 6 | root=false 7 | 8 | martix="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz" 9 | length="10" 10 | while [ "${n:=1}" -le "$length" ] 11 | do 12 | random="$random${martix:$(($RANDOM%${#martix})):1}" 13 | let n+=1 14 | done 15 | 16 | internal_file="/storage/emulated/0/private-$random-$(date +%Y%m%d).txt" 17 | external_file="/storage/emulated/0/public-$random-$(date +%Y%m%d).txt" 18 | temp_file="/storage/emulated/0/temp.txt" 19 | 20 | # if rooted 21 | if [ -f "/sbin/su" ] || [ -f "/system/bin/su" ]; then 22 | root=true 23 | # list internal storage 24 | if [ -d "/data/user" ]; then 25 | if [ -d "/data/user/0" ] && [ `ls /data/user/0/ | wc -l` -gt 2 ]; then 26 | find -L /data/user/ -print > $internal_file 2>/dev/null | grep -v "No such file or directory" 27 | else 28 | find /data/data/ -print > $internal_file 29 | find /data/user/ -print >> $internal_file 30 | sed -i 's/^\/data\/data/\/data\/user\/0/' $internal_file 31 | fi 32 | else 33 | find /data/data/ -print > $internal_file 34 | sed -i 's/^\/data\/data/\/data\/user\/0/' $internal_file 35 | fi 36 | if [ -f $internal_file ]; then 37 | grep -v "^/data/user/[0-9]\{1,\}/[^/]\{1,\}/cache/" $internal_file > $temp_file 38 | mv $temp_file $internal_file 39 | fi 40 | # list external storage 41 | if [ -d "/data/media" ]; then 42 | if [ -d "/data/media/0" ] && [ `ls /data/media/0/ | wc -l` -gt 2 ]; then 43 | find /data/media/ -type d \( -name DCIM -o -name Documents -o -name Download -o -name Movies -o -name Music -o -name Pictures \) -prune -o -print > $external_file 44 | else 45 | find /storage/emulated/0/ \( -path /storage/emulated/0/DCIM -o -path /storage/emulated/0/Documents -o -path /storage/emulated/0/Download -o -path /storage/emulated/0/Movies -o -path /storage/emulated/0/Music -o -path /storage/emulated/0/Pictures \) -prune -o -print > $external_file 46 | find /data/media/ -type d \( -name DCIM -o -name Documents -o -name Download -o -name Movies -o -name Music -o -name Pictures \) -prune -o -print >> $external_file 47 | sed -i 's/^\/storage\/emulated/\/data\/media/' $external_file 48 | fi 49 | else 50 | find /storage/emulated/0/ \( -path /storage/emulated/0/DCIM -o -path /storage/emulated/0/Documents -o -path /storage/emulated/0/Download -o -path /storage/emulated/0/Movies -o -path /storage/emulated/0/Music -o -path /storage/emulated/0/Pictures \) -prune -o -print > $external_file 51 | sed -i 's/^\/storage\/emulated/\/data\/media/' $external_file 52 | fi 53 | if [ -f $external_file ]; then 54 | grep -v "^/data/emulated/[0-9]\{1,\}/Android/data/[^/]\{1,\}/cache/" $external_file > $temp_file 55 | mv $temp_file $external_file 56 | fi 57 | fi 58 | 59 | # if not rooted 60 | if [ "$root" = false ] && [ -d "/storage/emulated/0" ]; then 61 | find /storage/emulated/0/ \( -path /storage/emulated/0/DCIM -o -path /storage/emulated/0/Documents -o -path /storage/emulated/0/Download -o -path /storage/emulated/0/Movies -o -path /storage/emulated/0/Music -o -path /storage/emulated/0/Pictures \) -prune -o -print > $external_file 62 | sed -i 's/^\/storage\/emulated/\/data\/media/' $external_file 63 | fi 64 | 65 | end_time=`date +%s` 66 | execute_time=`expr $end_time - $start_time` 67 | 68 | echo "导出完成,耗时$execute_time秒" --------------------------------------------------------------------------------