国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > BAT > 正文

自動清除電腦垃圾及刪除windows默認共享盤符的批處理bat

2020-06-09 14:17:21
字體:
來源:轉載
供稿:網友
by:zuifeng258
Windows在默認情況下幾個盤多是共享的,它們是隱藏的危險。
在dos下用命令“net share”可以查看。。。
不能截圖,就只能打打字了
復制代碼 代碼如下:

@echo off
echo 正在自動刪除admin$管理共享和ipc$管道共享,
net share admin$ /del
net share IPC$ /del
net share C$ /del
net share D$ /del
net share E$ /del
net share F$ /del

@echo off并不是DOS程序中的,
而是DOS批處理中的。
當年的DOS,所有操作都用鍵盤命令來完成,
當你每次都要輸入相同的命令時,
可以把這么多命令存為一個批處理。
上面那段是默認admin$管理共享和ipc$管道共享的命令
如果那沒有這么多盤符,可以照上面的“net shere *$” /del ' *是你的盤符號。進行增減


復制代碼 代碼如下:

@echo off
echo 這是正在檢查cookies、歷史紀錄等目錄位置(當前用戶)……
reg query "HKCU/software/Microsoft/Windows/CurrentVersion/Explorer/Shell Folders" /v Cache>%temp%/cleantmp.txt
reg query "HKCU/software/Microsoft/Windows/CurrentVersion/Explorer/Shell Folders" /v Cookies>>%temp%/cleantmp.txt
reg query "HKCU/software/Microsoft/Windows/CurrentVersion/Explorer/Shell Folders" /v History>>%temp%/cleantmp.txt
reg query "HKCU/software/Microsoft/Windows/CurrentVersion/Explorer/Shell Folders" /v NetHood>>%temp%/cleantmp.txt
reg query "HKCU/software/Microsoft/Windows/CurrentVersion/Explorer/Shell Folders" /v Recent>>%temp%/cleantmp.txt

echo 這里是 清理當前用戶的Cookies,IE緩存,歷史紀錄等……
for /f "tokens=3*" %%i in (%temp%/cleantmp.txt) do (
for /d %%i in ("%%i %%b/*.*") do rd /q /s "%%i">Nul 2>Nul
del /a /f /s /q "%%i %%b/*.*">Nul 2>Nul
)

echo 這里清理系統臨時垃圾文件……
del /a /f /s /q "%userprofile%/Locals~1/Tempor~1/*.*" >Nul 2>Nul
del /a /f /s /q "%userprofile%/Locals~1/Temp/*.*" >Nul 2>Nul
del /a /f /s /q "%userprofile%/cookies/*.*" >Nul 2>Nul
del /a /f /s /q "%userprofile%/recent/*.*" >Nul 2>Nul
del /a /f /s /q "%Temp%/*.*" >Nul 2>Nul
del /a /f /s /q "%Tmp%/*.*" >Nul 2>Nul
del /a /f /s /q "%HomePath%/../IconCache.db" >Nul 2>Nul
del /a /f /s /q "%SystemDrive%/driver?/*.pnf" >Nul 2>Nul
del /a /f /s /q "%SystemDrive%/driver?/InfCache.1" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/*._mp" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/*.bak" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/kb*.log" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/*.dmp" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/*.gid" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/*.old" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/*.query" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/*.tmp" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/inf/InfCache.1" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/driver?/*.pnf" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/driver?/InfCache.1" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/inf/*.pnf" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/minidump/*.*" >Nul 2>Nul
del /a /f /s /q "%SystemRoot%/Prefetch/*.*" >Nul 2>Nul
for %%i in (c d e f g h i j k l m n o p q r s t u v w x y z) do del /a /f /q %%i:/autorun.inf %%i:/*.exe & rd /q /s %%i:/recycler %%i:/recycled
rd /q /s "%ProgramFiles%/InstallShield Installation Information" >Nul 2>Nul
rd /q /s "%systemdrive%/Documents and Settings/All Users/Documents/My BoBoTurbo" >Nul 2>Nul
rd /q /s "%systemroot%/Connection Wizard" >Nul 2>Nul
rd /q /s "%systemroot%/Downloaded Installations" >Nul 2>Nul
rd /q /s "%SystemRoot%/Help" >Nul 2>Nul
rd /q /s "%systemroot%/ie7updates" & md "%systemroot%/ie7updates" >Nul 2>Nul
rd /q /s "%SystemRoot%/Offline Web Pages" >Nul 2>Nul
rd /q /s %SystemRoot%/system32/oobe
rd /q /s "%SystemRoot%/system32/ReinstallBackups" >Nul 2>Nul
rd /q /s "%SystemRoot%/SoftwareDistribution/Download" & md "%SystemRoot%/SoftwareDistribution/Download" >Nul 2>Nul
rd /q /s "%SystemRoot%/SoftwareDistribution/datastore" & md "%SystemRoot%/SoftwareDistribution/datastore" >Nul 2>Nul
rd /q /s "%SystemRoot%/SoftwareDistribution/EventCache" & md "%SystemRoot%/SoftwareDistribution/EventCache" >Nul 2>Nul
rd /q /s "%SystemRoot%/temp" & md "%SystemRoot%/temp" >Nul 2>Nul
發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 田林县| 哈巴河县| 石狮市| 柳州市| 阳高县| 靖安县| 鄂尔多斯市| 新营市| 肥城市| 苍梧县| 肇东市| 杂多县| 凤庆县| 旌德县| 阜新| 龙里县| 蒲江县| 开平市| 福安市| 静安区| 河西区| 台山市| 永嘉县| 大姚县| 保德县| 建德市| 阆中市| 松潘县| 久治县| 隆子县| 黑河市| 正蓝旗| 长春市| 宁晋县| 漯河市| 丰原市| 开封县| 罗山县| 沛县| 灌南县| 津市市|