本帖最后由 cutebe 于 2012-10-23 21:16 编辑
- @ECHO OFF
- FOR %%D IN (D E F G H I J K L M N O P Q R S T U V W X Y Z)DO IF EXIST %%D: CALL :DRV %%D:
- GOTO :EOF
-
- :DRV DRIVE:
- FOR /F "DELIMS=" %%F IN ('DIR/AD/S/B %1')DO (
- IF NOT EXIST "%%F\DESKTOP.INI\" (
- IF EXIST "%%F\DESKTOP.INI" (
- IF NOT EXIST "%%F\INFO2\" (
- IF NOT EXIST "%%F\INFO2" (
- DEL/A/F/Q "%%F\DESKTOP.INI"
- ATTRIB -S -H -R "%%F"
- )
- )ELSE (
- DEL/A/F/Q "%%F\DESKTOP.INI"
- ATTRIB -S -H -R "%%F"
- )
- )
- )
- )
复制代码
|