使用批处理命令删除系统垃圾文件
昨天看到一个帖子,使用批处理命令可以在大约一分钟内删除C盘系统垃圾文件。试着使用,删除文件后,我查看了下我的C盘空间容量,发现减少了300多MB垃圾文件。 使用方法:打开“记事本”新建一个文档,输入一下内容,保存为“deltempfile.bat”或者其他名字,后缀一定要使用bat。适用于98,2000,XP系统。最后用鼠标双击这个文件,它会自动删除C盘下的垃圾文件。 代码@echo off echo 正在清除系统垃圾文件,请稍候...... del /f /s /q %systemdrive%\*.tmp del /f /s /q %systemdrive%\*._mp 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 Windows在安装和使用过程中产生的垃圾包括临时文件(如*.tmp、*._mp等)、临时备份文件(如*.bak、*.old、*.syd等)、临时帮助文件(*.gid)、磁盘检查数据文件(*.chk)以及*.dir、*.dmp、*.nch等其他临时文件。 本文出自 51CTO.COM技术博客 |


代码
红衣主教
博客统计信息
热门文章
最新评论
友情链接