大家有没有遇到电脑里有很多垃圾文件,但是又不想下载第三方软件来清理垃圾文件,那该怎么办呢?今天小编就教大家怎么在win10系统上创建一个一键清理win10系统垃圾文件小程序。
具体步骤如下:
1.在桌面上空白处右键新建一个文本文档;
2.打开这个文本文档,将下列代码复制进去:
@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 SettingsTemporary Internet Files*.*”
del /f /s /q “%userprofile%Local SettingsTemp*.*”
del /f /s /q “%userprofile%recent*.*”
echo 清除系统LJ完成!
echo. & pause
3.接着"保存",关闭之后将这个文本文档名字改为"一键清理",后缀名改为"bat";
4.然后我们右键选择"以管理员身份运行";
5.接着这个程序就会自动清理电脑中的垃圾文件了。
以上就是win10电脑怎么清理的具体教程,大家可以尝试一下非常简单,希望能给大家带来帮助。

