0%
前言
Windows垃圾清理脚本
通过垃圾清理脚本清理垃圾
创建文件

修改文件扩展名
- 右键->重命名->”垃圾清理.bat”->(是否更改扩展名)是

写入代码

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
| @echo off echo 正在清除系统垃圾文件,请稍等...... del /f /s /q %systemdrive%\*.tmp del /f /s /q %systemdrive%\*._mp del /f /s /q %systemdrive%\*.log del /f /s /q %systemdrive%\*.gid del /f /s /q %systemdrive%\*.chk del /f /s /q %systemdrive%\*.old del /f /s /q %systemdrive%\recycled\*.* del /f /s /q %windir%\*.bak del /f /s /q %windir%\prefetch\*.* rd /s /q %windir%\temp & md %windir%\temp del /f /q %userprofile%\cookies\*.* del /f /q %userprofile%\recent\*.* del /f /s /q "%userprofile%\Local Settings\Temporary Internet Files\*.*" del /f /s /q "%userprofile%\Local Settings\Temp\*.*" del /f /s /q "%userprofile%\recent\*.*" echo 清除系统垃圾完成!!! echo. & pause
|
运行程序

完成

手动删除无用文件
1 2 3 4 5 6 7 8 9 10
| ::删除系统临时文件缓存 rd C:\Windows\Temp\ /s /q ::系统升级时下载的漏洞补丁和修复程序 rd C:\Windows\SoftwareDistribution\Download\ /s /q ::软件的日志 rd C:\Windows\System32\LogFiles\ /s /q ::系统存放的文件预读信息,用于加速访问 rd C:\Windows\Prefetch\ /s /q ::临时备份文件 rd C:\Windows\WinSxS\Backup\ /s /q
|
在系统设置中删除临时文件


参考文献
小红书——华硕
小红书——田同学Tino