批處理文件如下:
@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 清除System junk完成!
echo. & pause
======
@echo off
color 1B
title 清理系統垃圾工具
echo 正在清理系統垃圾及安裝殘留文件,請稍等......
del /f /s /q %systemdrive%\*.tmp
del /f /s /q %systemdrive%\*._mp
del /f /s /q %systemdrive%\*.log
del /f /s /q %systemdrive%\*.ms
del /f /s /q %systemdrive%\*.gid
del /f /s /q %systemdrive%\*.chk
del /f /s /q %systemdrive%\*.old
del /f /s /q %systemdrive%\*.ftg
del /f /s /q %systemdrive%\*.fts
del /f /s /q %systemdrive%\*.syd
del /f /s /q %systemdrive%\*.diz
del /f /s /q %systemdrive%\*.??$
del /f /s /q %systemdrive%\*.??~
del /f /s /q "%systemdrive%\*.$$$
del /f /s /q "%systemdrive%\*.~*
del /f /s /q "%systemdrive%\*.@@@
del /f /s /q %systemdrive%\recycled\*.*
del /a /f /s /q %systemroot%\*.query
del /f /s /q %systemRoot%\Downloaded Program Files\*.*
del /f /s /q %systemRoot%\Offline Web Pages\*.*
del /f /s /q %systemRoot%\*.bak
del /f /s /q %windir%\*.bak
del /f /s /q %windir%\*.log
del /f /s /q %windir%\*.tmp
del /f /s /q %windir%\prefetch\*.*
rd /s /q %windir%\temp & md %windir%\temp
rd/s/q %windir%\temp & md %windir%\tempemp% &md %temp%
del /f /s /q "%appdata%\Microsoft\Windows\cookies\*.*
rd /S /q %systemRoot%\temp" & md "%systemRoot%\temp
del /f /q %userprofile%\s\*.*
del /f /q %userprofile%\S s\*.*
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%\AppData\Roaming\Microsoft\Windows\Cookies\*.txt"
del /f /s /q "%userprofile%\Local Settings\Temp\*.*"
del /f /s /q "%userprofile%\recent\*.*"
del /f /s /q %windir%\SoftwareDistribution\Download\*.*
rd /s /q "%userprofile%\Local Settings\Temp\" & md "%userprofile%\Local Settings\Temp\"
del /f /s /q "%appdata%\Microsoft\Windows\Recent\*.*"
for /d %%a in ("%temp%\*.*") do rd /s /q "%%a"
del /a /f /s /q "%temp%\*.*" 2>nul
for /d %%a in ("%tmp%\*.*") do rd /s /q "%%a"
del /a /f /s /q "%tmp%\*.*" 2>nul
for /f "tokens=1" %%i in ('dir %SystemRoot%\$*$ /s /b /ad') do rd /s /q %%i
echo 正在正在清理IE緩存、cookies、歷史紀錄等(當前用戶)...
reg query "HKCU\software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v Cache>vtemp.txt
reg query "HKCU\software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v Cookies>>vtemp.txt
reg query "HKCU\software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v History>>vtemp.txt
reg query "HKCU\software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v NetHood>>vtemp.txt
reg query "HKCU\software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v Recent>>vtemp.txt
for /f "tokens=3*" %%a in (vtemp.txt) do (
for /d %%i in ("%%a %%b\*.*") do rd /s /q "%%i" 2>Nul
del /a /f /s /q "%%a %%b\*.*" del /q vtemp.txt 2>Nul
)
echo 清除瀏覽器地址記錄...
reg delete "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\TypedUrls" /f 2>nul
REG ADD "HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\TypedUrls"
echo 清除運行記錄...
reg delete "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\RunMRU" /f 2>nul
REG ADD "HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\RunMRU" /v "MRUList" /t reg_sz /d "a" /f
sfc /purgecache '清理系統盤無用文件
defrag %systemdrive% -b '優化預讀信息
cls
echo 系統垃圾清理完成!
批處理清理系統垃圾_xp
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章
批處理清理系統垃圾_xp
xmyklw
2019-02-22 21:50:51
CCleaner使用說明
wang99239523
2019-02-22 17:15:08
jquery.cookie.js使用介紹
老客網絡
2019-02-22 23:57:10
php中curl的詳細解說
朱娜娜
2019-02-22 23:43:01
登錄成功返回登錄前頁面js代碼
小旭依然
2019-02-22 21:49:35
彌補Web開發缺陷 實戰HTML 5中存儲API
123cgn
2019-02-22 20:57:35
利用cookies實現對彈出窗口頻率的控制
外星人et59
2019-02-22 20:54:20
優化Linux系統內核/etc/sysctl.conf
taokey_linux
2019-02-22 20:14:21
微軟高管:cookies基本安全
李玉平ys
2019-02-22 19:58:59
JMeter——HTTP COOKIE Manager(cookie管理器)
葉子文文
2019-02-22 17:43:27
Cookies 必須啓用才能登入。
19001989
2019-02-22 16:26:18
selenium獲取cookies
知止內明
2019-02-22 14:46:36
selenium獲取cookies
知止內明
2019-01-29 13:02:27
跨域讀寫Cookie 轉
龐陸陽
2018-12-02 21:17:46