无忧启动论坛

 找回密码
 注册
搜索
系统gho:最纯净好用系统下载站投放广告、加入VIP会员,请联系 微信:wuyouceo
查看: 7302|回复: 20
打印 上一主题 下一主题

[原创] 批处理迁移系统用户文件夹位置

    [复制链接]
跳转到指定楼层
1#
发表于 2017-12-3 23:10:34 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
分两个版本:XP (1楼)及 更高(2楼)
适用于 XP 的批处理:
  1. @echo off
  2. title 移动目标文件夹位置向导 by chishingchan
  3. for /f "tokens=2 delims=[]" %%i in ('ver') do @set FullVer=%%i
  4. for /f "tokens=2,3 delims=. " %%i in ('echo %FullVer%') do @set Ver=%%i
  5. if %Ver% NEQ 5 mshta vbscript:CreateObject("Wscript.Shell").popup("请运行在 Windows XP 系统版本!",4,"提示",64)(window.close)&&exit

  6. set drive=.
  7. set choice=.
  8. SETLOCAL ENABLEDELAYEDEXPANSION
  9. set Name=
  10. for /f "tokens=3" %%i in ('wmic logicaldisk where DriveType^=3 Get FileSystem^,FreeSpace^,Name^,Size^|findstr ":"') do if not %%i==%SystemDrive% set Name=%%i !Name!
  11. set choice=!Name!
  12. for %%i in (%choice%) do if exist %%i\nul if not exist "%%i\Windows\explorer.exe" set drive=%%i
  13. SETLOCAL DISABLEDELAYEDEXPANSION
  14. if "%drive%"=="." mshta vbscript:CreateObject("Wscript.Shell").popup("没有发现可用的驱动器!",4,"错误",64)(window.close)&&exit

  15. if "%1"=="/?" goto help
  16. if "%1"=="/h" goto help
  17. if "%1"=="/H" goto help
  18. if "%1"=="/u" goto copyfiles
  19. if "%1"=="/U" goto copyfiles

  20. echo 正在检测系统,请稍候...
  21. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Desktop" ^|findstr "Desktop"') do set Current_Desktop=%%b>nul 2>nul
  22. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Personal" ^|findstr "Personal"') do set Current_Personal=%%b>nul 2>nul
  23. for /f "tokens=3*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Pictures" ^|findstr "Pictures"') do set Current_My_Pictures=%%b>nul 2>nul
  24. for /f "tokens=3*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Video" ^|findstr "Videos"') do set Current_My_Video=%%b>nul 2>nul
  25. if "%Current_My_Video%"=="" set Current_My_Video=%Current_Personal%\My Videos&&reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Video" /t REG_SZ /d "%Current_Personal%\My Videos">nul 2>nul
  26. for /f "tokens=3*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Music" ^|findstr "Music"') do set Current_My_Music=%%b>nul 2>nul
  27. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Favorites" ^|findstr "Favorites"') do set Current_Favorites=%%b>nul 2>nul
  28. for /f "tokens=3*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Internet Explorer" /v "Download Directory" ^|findstr "Download"') do set Current_Downloads=%%b>nul 2>nul
  29. if "%Current_Downloads%"=="" set Current_Downloads=%USERPROFILE%\Downloads&&reg add "HKCU\Software\Microsoft\Internet Explorer" /f /v "Download Directory" /t REG_SZ /d "%USERPROFILE%\Downloads">nul 2>nul

  30. for /f "tokens=2*" %%a in ('REG QUERY "HKLM\SYSTEM\CurrentControlSet\Control\Nls\Language" /v "InstallLanguage" ^|findstr "InstallLanguage"') do set InstallLanguage=%%b>nul 2>nul
  31. if %InstallLanguage%==0412 (
  32. for /f "tokens=3*" %%a in ('REG QUERY "HKLM\SOFTWARE\Classes\CLSID\{00021400-0000-0000-C000-000000000046}" /ve ^|findstr "REG_SZ"') do set Desktop=%%b>nul 2>nul
  33. ) else (
  34. for /f "tokens=2*" %%a in ('REG QUERY "HKLM\SOFTWARE\Classes\CLSID\{00021400-0000-0000-C000-000000000046}" /ve ^|findstr "REG_SZ"') do set Desktop=%%b>nul 2>nul
  35. )

  36. :input
  37. cls
  38. echo 当前目标文件夹位置:
  39. echo.
  40. echo 『桌面』     "%Current_Desktop%"
  41. echo 『我的文档』 "%Current_Personal%"
  42. echo 『图片收藏』 "%Current_My_Pictures%"
  43. echo 『我的视频』 "%Current_My_Video%"
  44. echo 『我的音乐』 "%Current_My_Music%"
  45. echo 『收藏夹』   "%Current_Favorites%"
  46. echo 『下载』     "%Current_Downloads%"
  47. echo.
  48. set Drive_Letter=%drive%
  49. set /P Drive_Letter="请输入指令或目标驱动器(默认值:%drive%) [ H | Q | U | %choice%] "
  50. echo.
  51. rem 转换输入字符串为大写
  52. for /f "delims=" %%a in ('tree "\$\%Drive_Letter%"^|find /i ":\$\%Drive_Letter%"') do set Drive_Letter=%%~nxa
  53. set select=%Drive_Letter%
  54. set Same=N
  55. if "%Current_Desktop:~0,1%"=="%Drive_Letter:~0,1%" set Same=Y
  56. if "%Drive_Letter%"=="" set Drive_Letter=%drive%
  57. if "%Drive_Letter%"=="H" goto help
  58. if "%Drive_Letter%"=="Q" mshta vbscript:CreateObject("Wscript.Shell").popup("正在退出向导...",2,"移动目标文件夹位置",64)(window.close)&&exit
  59. if "%Drive_Letter%"=="U" goto copyfiles
  60. rem 如果输入在提示行之外的字符,即返回
  61. echo %Drive_Letter%|findstr "%choice%">nul 2>nul
  62. if %errorlevel%==1 goto input

  63. :Users
  64. set XP=N
  65. set CopyFile=N
  66. set DelFile=N
  67. set /P XP="是否使用 WinXP 目录结构文件夹(默认值:N) [ 返回(R) | 是(Y) | 否(N) ] "
  68. echo.
  69. rem 转换输入字符串为大写
  70. for /f "delims=" %%a in ('tree "\$\%XP%"^|find /i ":\$\%XP%"') do set XP=%%~nxa
  71. if "%XP%"=="" set XP=N
  72. if "%XP%"=="R" goto input
  73. if "%XP%"=="Y" set HP=\Documents and Settings\%USERNAME%
  74. if "%XP%"=="N" set HP=\Users\%USERNAME%
  75. rem 如果输入在提示行之外的字符,即返回
  76. echo %XP%|findstr "R Y N">nul 2>nul
  77. if %errorlevel%==1 goto Users
  78. :: if %Same%==Y goto Start

  79. :copyfiles
  80. rem set CopyFile=N
  81. set /P CopyFile="是否复制文件夹到目标驱动器(默认值:N) [ 返回(R) | 是(Y) | 否(N) ] "
  82. echo.
  83. rem 转换输入字符串为大写
  84. for /f "delims=" %%a in ('tree "\$\%CopyFile%"^|find /i ":\$\%CopyFile%"') do set CopyFile=%%~nxa
  85. if "%CopyFile%"=="" set CopyFile=N
  86. if "%CopyFile%"=="R" goto input
  87. rem 如果输入在提示行之外的字符,即返回
  88. echo %CopyFile%|findstr "R Y N">nul 2>nul
  89. if %errorlevel%==1 goto copyfiles

  90. :delsource
  91. rem set DelFile=N
  92. set /P DelFile="是否从源驱动器删除文件夹(默认值:N) [ 返回(R) | 是(Y) | 否(N) ] "
  93. echo.
  94. rem 转换输入字符串为大写
  95. for /f "delims=" %%a in ('tree "\$\%DelFile%"^|find /i ":\$\%DelFile%"') do set DelFile=%%~nxa
  96. if "%DelFile%"=="" set DelFile=N
  97. if "%DelFile%"=="R" goto input
  98. rem 如果输入在提示行之外的字符,即返回
  99. echo %DelFile%|findstr "R Y N">nul 2>nul
  100. if %errorlevel%==1 goto delsource

  101. if "%Drive_Letter%"=="u" goto default
  102. if "%Drive_Letter%"=="U" goto default
  103. echo ================================= 移动文件夹 ==================================
  104. echo 目标驱动器:%Drive_Letter%%HP%
  105. echo 复制文件夹:%CopyFile%
  106. echo 删除源文件:%DelFile%
  107. echo ===============================================================================
  108. echo.&&pause&&echo.

  109. :Start
  110. echo 正在处理『桌面』...
  111. md "%Drive_Letter%%HP%\%Desktop%">nul 2>nul
  112. if %CopyFile%==Y xcopy "%Current_Desktop%\*.*" "%Drive_Letter%%HP%\%Desktop%" /s /y>nul 2>nul
  113. attrib -r -a -s -h "%Drive_Letter%%HP%\%Desktop%\desktop.ini">nul 2>nul
  114. echo [.ShellClassInfo]>"%Drive_Letter%%HP%\%Desktop%\desktop.ini"
  115. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%Drive_Letter%%HP%\%Desktop%\desktop.ini"
  116. echo IconIndex=-181>>"%Drive_Letter%%HP%\%Desktop%\desktop.ini"
  117. echo LocalizedResourceName=@shell32.dll,-21769>>"%Drive_Letter%%HP%\%Desktop%\desktop.ini"
  118. attrib -r +a +s +h "%Drive_Letter%%HP%\%Desktop%\desktop.ini">nul 2>nul
  119. attrib -r +a +s -h "%Drive_Letter%%HP%\%Desktop%" /s /d>nul 2>nul
  120. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Desktop" /t REG_SZ /d "%Drive_Letter%%HP%\%Desktop%">nul 2>nul
  121. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Desktop" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\%Desktop%">nul 2>nul
  122. if %DelFile%==Y rd /s /q "%Current_Desktop%">nul 2>nul

  123. echo 正在处理『我的文档』...
  124. md "%Drive_Letter%%HP%\Documents">nul 2>nul
  125. if %CopyFile%==Y xcopy "%Current_Personal%\*.*" "%Drive_Letter%%HP%\Documents" /s /y>nul 2>nul
  126. attrib -r -a -s -h "%Drive_Letter%%HP%\Documents\desktop.ini">nul 2>nul
  127. echo [DeleteOnCopy]>"%Drive_Letter%%HP%\Documents\desktop.ini"
  128. echo Owner=%USERNAME%>>"%Drive_Letter%%HP%\Documents\desktop.ini"
  129. echo Personalized=^5>>"%Drive_Letter%%HP%\Documents\desktop.ini"
  130. echo PersonalizedName=My Documents>>"%Drive_Letter%%HP%\Documents\desktop.ini"
  131. attrib -r +a +s +h "%Drive_Letter%%HP%\Documents\desktop.ini">nul 2>nul
  132. attrib -r +a +s -h "%Drive_Letter%%HP%\Documents" /s /d>nul 2>nul
  133. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Personal" /t REG_SZ /d "%Drive_Letter%%HP%\Documents">nul 2>nul
  134. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Personal" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents">nul 2>nul
  135. if %DelFile%==Y rd /s /q "%Current_Personal%">nul 2>nul

  136. echo 正在处理『我的图片』...
  137. md "%Drive_Letter%%HP%\Documents\Pictures">nul 2>nul
  138. if %CopyFile%==Y xcopy "%Current_My_Pictures%\*.*" "%Drive_Letter%%HP%\Documents\Pictures" /s /y>nul 2>nul
  139. attrib -r -a -s -h "%Drive_Letter%%HP%\Documents\Pictures\desktop.ini">nul 2>nul
  140. echo [.ShellClassInfo]>"%Drive_Letter%%HP%\Documents\Pictures\desktop.ini"
  141. echo InfoTip=@Shell32.dll,-12688>>"%Drive_Letter%%HP%\Documents\Pictures\desktop.ini"
  142. echo IconFile=%SystemRoot%\system32\mydocs.dll>>"%Drive_Letter%%HP%\Documents\Pictures\desktop.ini"
  143. echo IconIndex=-101>>"%Drive_Letter%%HP%\Documents\Pictures\desktop.ini"
  144. echo LocalizedResourceName=@shell32.dll,-21779>>"%Drive_Letter%%HP%\Documents\Pictures\desktop.ini"
  145. attrib -r +a +s +h "%Drive_Letter%%HP%\Documents\Pictures\desktop.ini">nul 2>nul
  146. attrib -r +a +s -h "%Drive_Letter%%HP%\Documents\Pictures" /s /d>nul 2>nul
  147. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Pictures" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Pictures">nul 2>nul
  148. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Pictures" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Pictures">nul 2>nul
  149. if %DelFile%==Y rd /s /q "%Current_My_Pictures%">nul 2>nul

  150. echo 正在处理『我的视频』...
  151. md "%Drive_Letter%%HP%\Documents\Videos">nul 2>nul
  152. if %CopyFile%==Y xcopy "%Current_My_Video%\*.*" "%Drive_Letter%%HP%\Documents\Videos" /s /y>nul 2>nul
  153. attrib -r -a -s -h "%Drive_Letter%%HP%\Documents\Videos\desktop.ini">nul 2>nul
  154. echo [.ShellClassInfo]>"%Drive_Letter%%HP%\Documents\Videos\desktop.ini"
  155. echo InfoTip=@Shell32.dll,-12690>>"%Drive_Letter%%HP%\Documents\Videos\desktop.ini"
  156. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%Drive_Letter%%HP%\Documents\Videos\desktop.ini"
  157. echo IconIndex=-238>>"%Drive_Letter%%HP%\Documents\Videos\desktop.ini"
  158. echo LocalizedResourceName=@shell32.dll,-21791>>"%Drive_Letter%%HP%\Documents\Videos\desktop.ini"
  159. attrib -r +a +s +h "%Drive_Letter%%HP%\Documents\Videos\desktop.ini">nul 2>nul
  160. attrib -r +a +s -h "%Drive_Letter%%HP%\Documents\Videos" /s /d>nul 2>nul
  161. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Video" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Videos">nul 2>nul
  162. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Video" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Videos">nul 2>nul
  163. if %DelFile%==Y rd /s /q "%Current_My_Video%">nul 2>nul

  164. echo 正在处理『我的音乐』...
  165. md "%Drive_Letter%%HP%\Documents\Music">nul 2>nul
  166. if %CopyFile%==Y xcopy "%Current_My_Music%\*.*" "%Drive_Letter%%HP%\Documents\Music" /s /y>nul 2>nul
  167. attrib -r -a -s -h "%Drive_Letter%%HP%\Documents\Music\desktop.ini">nul 2>nul
  168. echo [.ShellClassInfo]>"%Drive_Letter%%HP%\Documents\Music\desktop.ini"
  169. echo InfoTip=@Shell32.dll,-12689>>"%Drive_Letter%%HP%\Documents\Music\desktop.ini"
  170. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%Drive_Letter%%HP%\Documents\Music\desktop.ini"
  171. echo IconIndex=-237>>"%Drive_Letter%%HP%\Documents\Music\desktop.ini"
  172. echo LocalizedResourceName=@shell32.dll,-21790>>"%Drive_Letter%%HP%\Documents\Music\desktop.ini"
  173. attrib -r +a +s +h "%Drive_Letter%%HP%\Documents\Music\desktop.ini">nul 2>nul
  174. attrib -r +a +s -h "%Drive_Letter%%HP%\Documents\Music" /s /d>nul 2>nul
  175. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Music" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Music">nul 2>nul
  176. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Music" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Music">nul 2>nul
  177. if %DelFile%==Y rd /s /q "%Current_My_Music%">nul 2>nul

  178. echo 正在处理『收藏夹』...
  179. md "%Drive_Letter%%HP%\Favorites">nul 2>nul
  180. if %CopyFile%==Y xcopy "%Current_Favorites%\*.*" "%Drive_Letter%%HP%\Favorites" /s /y>nul 2>nul
  181. attrib -r -a -s -h "%Drive_Letter%%HP%\Favorites\desktop.ini">nul 2>nul
  182. echo [.ShellClassInfo]>"%Drive_Letter%%HP%\Favorites\desktop.ini"
  183. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%Drive_Letter%%HP%\Favorites\desktop.ini"
  184. echo IconIndex=-173>>"%Drive_Letter%%HP%\Favorites\desktop.ini"
  185. echo LocalizedResourceName=@shell32.dll,-12693>>"%Drive_Letter%%HP%\Favorites\desktop.ini"
  186. attrib -r +a +s +h "%Drive_Letter%%HP%\Favorites\desktop.ini">nul 2>nul
  187. attrib -r +a +s -h "%Drive_Letter%%HP%\Favorites" /s /d>nul 2>nul
  188. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Favorites" /t REG_SZ /d "%Drive_Letter%%HP%\Favorites">nul 2>nul
  189. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Favorites" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Favorites">nul 2>nul
  190. if %DelFile%==Y rd /s /q "%Current_Favorites%">nul 2>nul

  191. echo 正在处理『下载』...
  192. md "%Drive_Letter%%HP%\Documents\Downloads">nul 2>nul
  193. if %CopyFile%==Y xcopy "%Current_Downloads%\*.*" "%Drive_Letter%%HP%\Documents\Downloads" /s /y>nul 2>nul
  194. attrib -r -a -s -h "%Drive_Letter%%HP%\Documents\Downloads\desktop.ini">nul 2>nul
  195. echo [.ShellClassInfo]>"%Drive_Letter%%HP%\Documents\Downloads\desktop.ini"
  196. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%Drive_Letter%%HP%\Documents\Downloads\desktop.ini"
  197. echo IconIndex=-326>>"%Drive_Letter%%HP%\Documents\Downloads\desktop.ini"
  198. echo LocalizedResourceName=@shell32.dll,-21782>>"%Drive_Letter%%HP%\Documents\Downloads\desktop.ini"
  199. attrib -r +a +s +h "%Drive_Letter%%HP%\Documents\Downloads\desktop.ini">nul 2>nul
  200. attrib -r +a +s -h "%Drive_Letter%%HP%\Documents\Downloads" /s /d>nul 2>nul
  201. reg add "HKCU\Software\Microsoft\Internet Explorer" /f /v "Download Directory" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Downloads">nul 2>nul
  202. if %DelFile%==Y rd /s /q "%Current_Downloads%">nul 2>nul

  203. attrib -r -a -s -h "%USERPROFILE%\Local Settings\Application Data\IconCache.db">nul 2>nul
  204. del /f /q "%USERPROFILE%\Local Settings\Application Data\IconCache.db">nul 2>nul
  205. taskkill /f /im explorer.exe
  206. start explorer.exe
  207. exit

  208. :default
  209. echo ================================= 还原默认值 ==================================
  210. echo 目标驱动器:%USERPROFILE%
  211. echo 复制文件夹:%CopyFile%
  212. echo 删除源文件:%DelFile%
  213. echo ===============================================================================
  214. echo.&&pause&&echo.
  215. set Drive_Letter=%HOMEDRIVE%
  216. echo.
  217. echo 正在处理『桌面』...
  218. md "%USERPROFILE%\%Desktop%">nul 2>nul
  219. if %CopyFile% EQU Y xcopy "%Current_Desktop%\*.*" "%USERPROFILE%\%Desktop%" /s /y>nul 2>nul
  220. attrib -r +a +s -h "%USERPROFILE%\%Desktop%" /s /d>nul 2>nul
  221. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Desktop" /t REG_SZ /d "%USERPROFILE%\%Desktop%">nul 2>nul
  222. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Desktop" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\%Desktop%">nul 2>nul
  223. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Desktop%">nul 2>nul

  224. echo 正在处理『我的文档』...
  225. md "%USERPROFILE%\My Documents">nul 2>nul
  226. if %CopyFile% EQU Y xcopy "%Current_Personal%\*.*" "%USERPROFILE%\My Documents" /s /y>nul 2>nul
  227. attrib -r -a -s -h "%USERPROFILE%\My Documents\desktop.ini">nul 2>nul
  228. echo [DeleteOnCopy]>"%USERPROFILE%\My Documents\desktop.ini"
  229. echo Owner=%USERNAME%>>"%USERPROFILE%\My Documents\desktop.ini"
  230. echo Personalized=^5>>"%USERPROFILE%\My Documents\desktop.ini"
  231. echo PersonalizedName=My Documents>>"%USERPROFILE%\My Documents\desktop.ini"
  232. attrib -r +a +s +h "%USERPROFILE%\My Documents\desktop.ini">nul 2>nul
  233. attrib -r +a +s -h "%USERPROFILE%\My Documents" /s /d>nul 2>nul
  234. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Personal" /t REG_SZ /d "%USERPROFILE%\My Documents">nul 2>nul
  235. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Personal" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\My Documents">nul 2>nul
  236. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Personal%">nul 2>nul

  237. echo 正在处理『我的图片』...
  238. md "%USERPROFILE%\My Documents\My Pictures">nul 2>nul
  239. if %CopyFile% EQU Y xcopy "%Current_My_Pictures%\*.*" "%USERPROFILE%\My Documents\My Pictures" /s /y>nul 2>nul
  240. attrib -r -a -s -h "%USERPROFILE%\My Documents\My Pictures\desktop.ini">nul 2>nul
  241. echo [.ShellClassInfo]>"%USERPROFILE%\My Documents\My Pictures\desktop.ini"
  242. echo InfoTip=@Shell32.dll,-12688>>"%USERPROFILE%\My Documents\My Pictures\desktop.ini"
  243. echo IconFile=%SystemRoot%\system32\mydocs.dll>>"%USERPROFILE%\My Documents\My Pictures\desktop.ini"
  244. echo IconIndex=-101>>"%USERPROFILE%\My Documents\My Pictures\desktop.ini"
  245. echo LocalizedResourceName=@shell32.dll,-21779>>"%USERPROFILE%\My Documents\My Pictures\desktop.ini"
  246. attrib -r +a +s +h "%USERPROFILE%\My Documents\My Pictures\desktop.ini">nul 2>nul
  247. attrib -r +a +s -h "%USERPROFILE%\My Documents\My Pictures" /s /d>nul 2>nul
  248. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Pictures" /t REG_SZ /d "%USERPROFILE%\My Documents\My Pictures">nul 2>nul
  249. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Pictures" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\My Documents\My Pictures">nul 2>nul
  250. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_My_Pictures%">nul 2>nul

  251. echo 正在处理『我的视频』...
  252. md "%USERPROFILE%\My Documents\My Videos">nul 2>nul
  253. if %CopyFile% EQU Y xcopy "%Current_My_Video%\*.*" "%USERPROFILE%\My Documents\My Videos" /s /y>nul 2>nul
  254. attrib -r -a -s -h "%USERPROFILE%\My Documents\My Videos\desktop.ini">nul 2>nul
  255. echo [.ShellClassInfo]>"%USERPROFILE%\My Documents\My Videos\desktop.ini"
  256. echo InfoTip=@Shell32.dll,-12690>>"%USERPROFILE%\My Documents\My Videos\desktop.ini"
  257. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%USERPROFILE%\My Documents\My Videos\desktop.ini"
  258. echo IconIndex=-238>>"%USERPROFILE%\My Documents\My Videos\desktop.ini"
  259. echo LocalizedResourceName=@shell32.dll,-21791>>"%USERPROFILE%\My Documents\My Videos\desktop.ini"
  260. attrib -r +a +s +h "%USERPROFILE%\My Documents\My Videos\desktop.ini">nul 2>nul
  261. attrib -r +a +s -h "%USERPROFILE%\My Documents\My Videos" /s /d>nul 2>nul
  262. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Video" /t REG_SZ /d "%USERPROFILE%\My Documents\My Videos">nul 2>nul
  263. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Video" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\My Documents\My Videos">nul 2>nul
  264. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_My_Video%">nul 2>nul

  265. echo 正在处理『我的音乐』...
  266. md "%USERPROFILE%\My Documents\My Music">nul 2>nul
  267. if %CopyFile% EQU Y xcopy "%Current_My_Music%\*.*" "%USERPROFILE%\My Documents\My Music" /s /y>nul 2>nul
  268. attrib -r -a -s -h "%USERPROFILE%\My Documents\My Music\desktop.ini">nul 2>nul
  269. echo [.ShellClassInfo]>"%USERPROFILE%\My Documents\My Music\desktop.ini"
  270. echo InfoTip=@Shell32.dll,-12689>>"%USERPROFILE%\My Documents\My Music\desktop.ini"
  271. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%USERPROFILE%\My Documents\My Music\desktop.ini"
  272. echo IconIndex=-237>>"%USERPROFILE%\My Documents\My Music\desktop.ini"
  273. echo LocalizedResourceName=@shell32.dll,-21790>>"%USERPROFILE%\My Documents\My Music\desktop.ini"
  274. attrib -r +a +s +h "%USERPROFILE%\My Documents\My Music\desktop.ini">nul 2>nul
  275. attrib -r +a +s -h "%USERPROFILE%\My Documents\My Music" /s /d>nul 2>nul
  276. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Music" /t REG_SZ /d "%USERPROFILE%\My Documents\My Music">nul 2>nul
  277. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Music" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\My Documents\My Music">nul 2>nul
  278. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_My_Music%">nul 2>nul

  279. echo 正在处理『收藏夹』...
  280. md "%USERPROFILE%\Favorites">nul 2>nul
  281. if %CopyFile% EQU Y xcopy "%Current_Favorites%\*.*" "%USERPROFILE%\Favorites" /s /y>nul 2>nul
  282. attrib -r -a -s -h "%USERPROFILE%\Favorites\desktop.ini">nul 2>nul
  283. echo [.ShellClassInfo]>"%USERPROFILE%\Favorites\desktop.ini"
  284. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%USERPROFILE%\Favorites\desktop.ini"
  285. echo IconIndex=-173>>"%USERPROFILE%\Favorites\desktop.ini"
  286. echo LocalizedResourceName=@shell32.dll,-12693>>"%USERPROFILE%\Favorites\desktop.ini"
  287. attrib -r +a +s +h "%USERPROFILE%\Favorites\desktop.ini">nul 2>nul
  288. attrib -r +a +s -h "%USERPROFILE%\Favorites" /s /d>nul 2>nul
  289. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Favorites" /t REG_SZ /d "%USERPROFILE%\Favorites">nul 2>nul
  290. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Favorites" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Favorites">nul 2>nul
  291. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Favorites%">nul 2>nul

  292. echo 正在处理『下载』...
  293. md "%USERPROFILE%\My Documents\Downloads">nul 2>nul
  294. if %CopyFile% EQU Y xcopy "%Current_Downloads%\*.*" "%USERPROFILE%\My Documents\Downloads" /s /y>nul 2>nul
  295. attrib -r -a -s -h "%USERPROFILE%\My Documents\Downloads\desktop.ini">nul 2>nul
  296. echo [.ShellClassInfo]>"%USERPROFILE%\My Documents\Downloads\desktop.ini"
  297. echo IconFile=%%SystemRoot%%\system32\SHELL32.dll>>"%USERPROFILE%\My Documents\Downloads\desktop.ini"
  298. echo IconIndex=-326>>"%USERPROFILE%\My Documents\Downloads\desktop.ini"
  299. echo LocalizedResourceName=@shell32.dll,-21782>>"%USERPROFILE%\My Documents\Downloads\desktop.ini"
  300. attrib -r +a +s +h "%USERPROFILE%\My Documents\Downloads\desktop.ini">nul 2>nul
  301. attrib -r +a +s -h "%USERPROFILE%\My Documents\Downloads" /s /d>nul 2>nul
  302. reg add "HKCU\Software\Microsoft\Internet Explorer" /f /v "Download Directory" /t REG_SZ /d "%USERPROFILE%\My Documents\Downloads">nul 2>nul
  303. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Downloads%">nul 2>nul

  304. rem 正在处理『图标缓存』...
  305. attrib -r -a -s -h "%USERPROFILE%\AppData\Local\IconCache.db">nul 2>nul
  306. del /f /q "%USERPROFILE%\AppData\Local\IconCache.db">nul 2>nul
  307. taskkill /f /im explorer.exe
  308. start explorer.exe
  309. exit

  310. :help
  311. echo 移动目标文件夹位置
  312. echo.
  313. echo  %~n0 [drive:] [/U] [/Q] [/H]
  314. echo.
  315. echo   drive:  目标驱动器
  316. echo   /U      还原默认值
  317. echo   /Q      退出向导
  318. echo   /H      显示帮助
  319. echo.
  320. echo 命令行键入 %~n0,可以启动一个向导。
  321. echo.
  322. if "%1"=="" pause&&goto input
复制代码

评分

参与人数 5无忧币 +23 收起 理由
fcurrk + 5 赞一个!
wuhuyou + 5 很给力!
GaMNiA + 5 很给力!
3ax31a + 5 赞一个!
xxw0815 + 3 很给力!

查看全部评分

推荐
发表于 2017-12-4 05:40:26 来自手机 | 只看该作者
终于看完了。。。。
回复

使用道具 举报

推荐
 楼主| 发表于 2017-12-3 23:11:00 | 只看该作者
  1. @echo off
  2. title 移动目标文件夹位置向导 by chishingchan
  3. for /f "tokens=2 delims=[]" %%i in ('ver') do @set FullVer=%%i
  4. for /f "tokens=2,3 delims=. " %%i in ('echo %FullVer%') do @set Ver=%%i
  5. if %Ver% LSS 6 mshta vbscript:CreateObject("Wscript.Shell").popup("请运行在 Windows 7/8/10 系统版本!",4,"提示",64)(window.close)&&exit

  6. set drive=.
  7. set choice=.
  8. SETLOCAL ENABLEDELAYEDEXPANSION
  9. set Name=
  10. for /f "tokens=3" %%i in ('wmic logicaldisk where DriveType^=3 Get FileSystem^,FreeSpace^,Name^,Size^|findstr ":"') do if not %%i==%SystemDrive% set Name=%%i !Name!
  11. set choice=!Name!
  12. for %%i in (%choice%) do if exist %%i\nul if not exist "%%i\Windows\explorer.exe" set drive=%%i
  13. SETLOCAL DISABLEDELAYEDEXPANSION
  14. if "%drive%"=="." mshta vbscript:CreateObject("Wscript.Shell").popup("没有发现可用的驱动器!",4,"错误",64)(window.close)&&exit

  15. if "%1"=="/?" goto help
  16. if "%1"=="/h" goto help
  17. if "%1"=="/H" goto help
  18. if "%1"=="/u" goto copyfiles
  19. if "%1"=="/U" goto copyfiles

  20. echo 正在检测系统,请稍候...
  21. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "{4C5C32FF-BB9D-43B0-B5B4-2D72E54EAAA4}" ^|findstr "Saved Games"') do set Current_Saved_Games=%%b
  22. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "{56784854-C6CB-462B-8169-88E350ACB882}" ^|findstr "Contacts"') do set Current_Contacts=%%b
  23. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "{BFB9D5E0-C6A9-404C-B2B2-AE6DB6AF4968}" ^|findstr "Links"') do set Current_Links=%%b
  24. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "{7D1D3A04-DEBB-4115-95CF-2F29DA2920DA}" ^|findstr "Searches"') do set Current_Searches=%%b
  25. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Favorites" ^|findstr "Favorites"') do set Current_Favorites=%%b
  26. for /f "tokens=3*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Video" ^|findstr "Videos"') do set Current_My_Video=%%b
  27. for /f "tokens=3*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Pictures" ^|findstr "Pictures"') do set Current_My_Pictures=%%b
  28. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Personal" ^|findstr "Documents"') do set Current_Personal=%%b
  29. for /f "tokens=3*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "My Music" ^|findstr "Music"') do set Current_My_Music=%%b
  30. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "{374DE290-123F-4565-9164-39C4925E467B}" ^|findstr "Downloads"') do set Current_Downloads=%%b
  31. for /f "tokens=2*" %%a in ('REG QUERY "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Desktop" ^|findstr "Desktop"') do set Current_Desktop=%%b

  32. :input
  33. cls
  34. echo 当前目标文件夹位置:
  35. echo.
  36. echo 『我的文档』        "%Current_Personal%"
  37. echo 『桌面』        "%Current_Desktop%"
  38. echo 『下载』        "%Current_Downloads%"
  39. echo 『收藏夹』        "%Current_Favorites%"
  40. echo 『我的图片』        "%Current_My_Pictures%"
  41. echo 『我的视频』        "%Current_My_Video%"
  42. echo 『我的音乐』        "%Current_My_Music%"
  43. echo 『保存的游戏』        "%Current_Saved_Games%"
  44. echo 『联系人』        "%Current_Contacts%"
  45. echo 『链接』        "%Current_Links%"
  46. echo 『搜索』        "%Current_Searches%"
  47. echo.
  48. set Drive_Letter=%drive%
  49. set /P Drive_Letter="请输入指令或目标驱动器(默认值:%drive%) [ H | Q | U | %choice%] "
  50. echo.
  51. rem 转换输入字符串为大写
  52. for /f "delims=" %%a in ('tree "\$\%Drive_Letter%"^|find /i ":\$\%Drive_Letter%"') do set Drive_Letter=%%~nxa
  53. set select=%Drive_Letter%
  54. if "%Current_Desktop:~0,1%"=="%Drive_Letter:~0,1%" mshta vbscript:CreateObject("Wscript.Shell").popup("输入的盘符与当前的盘符相同!",2,"错误",64)(window.close)&&goto input
  55. if "%Drive_Letter%"=="" set Drive_Letter=%drive%
  56. if "%Drive_Letter%"=="H" goto help
  57. if "%Drive_Letter%"=="Q" mshta vbscript:CreateObject("Wscript.Shell").popup("正在退出向导...",2,"移动目标文件夹位置",64)(window.close)&&goto end
  58. if "%Drive_Letter%"=="U" goto copyfiles
  59. rem 如果输入在提示行之外的字符,即返回
  60. echo %Drive_Letter%|findstr "%choice%">nul 2>nul
  61. if %errorlevel%==1 goto input

  62. :Users
  63. set XP=N
  64. set /P XP="是否使用 WinXP 目录结构文件夹(默认值:N) [ 返回(R) | 是(Y) | 否(N) ] "
  65. echo.
  66. rem 转换输入字符串为大写
  67. for /f "delims=" %%a in ('tree "\$\%XP%"^|find /i ":\$\%XP%"') do set XP=%%~nxa
  68. if "%XP%"=="" set XP=N
  69. if "%XP%"=="R" goto input
  70. if "%XP%"=="Y" set HP=\Documents and Settings\%USERNAME%
  71. if "%XP%"=="N" set HP=\Users\%USERNAME%
  72. rem 如果输入在提示行之外的字符,即返回
  73. echo %XP%|findstr "R Y N">nul 2>nul
  74. if %errorlevel%==1 goto Users

  75. :copyfiles
  76. set CopyFile=N
  77. set /P CopyFile="是否复制文件夹到目标驱动器(默认值:N) [ 返回(R) | 是(Y) | 否(N) ] "
  78. echo.
  79. rem 转换输入字符串为大写
  80. for /f "delims=" %%a in ('tree "\$\%CopyFile%"^|find /i ":\$\%CopyFile%"') do set CopyFile=%%~nxa
  81. if "%CopyFile%"=="" set CopyFile=N
  82. if "%CopyFile%"=="R" goto input
  83. rem 如果输入在提示行之外的字符,即返回
  84. echo %CopyFile%|findstr "R Y N">nul 2>nul
  85. if %errorlevel%==1 goto copyfiles

  86. :delsource
  87. set DelFile=N
  88. set /P DelFile="是否从源驱动器删除文件夹(默认值:N) [ 返回(R) | 是(Y) | 否(N) ] "
  89. echo.
  90. rem 转换输入字符串为大写
  91. for /f "delims=" %%a in ('tree "\$\%DelFile%"^|find /i ":\$\%DelFile%"') do set DelFile=%%~nxa
  92. if "%DelFile%"=="" set DelFile=N
  93. if "%DelFile%"=="R" goto input
  94. rem 如果输入在提示行之外的字符,即返回
  95. echo %DelFile%|findstr "R Y N">nul 2>nul
  96. if %errorlevel%==1 goto delsource

  97. if "%Drive_Letter%"=="u" goto default
  98. if "%Drive_Letter%"=="U" goto default
  99. echo ================================= 移动文件夹 ==================================
  100. echo 目标驱动器:%Drive_Letter%%HP%
  101. echo 复制文件夹:%CopyFile%
  102. echo 删除源文件:%DelFile%
  103. echo ===============================================================================
  104. echo.&&pause&&echo.
  105. echo 正在处理『我的文档』...
  106. md %Drive_Letter%%HP%\Documents>nul 2>nul
  107. if %CopyFile% EQU Y xcopy %Current_Personal%\*.* %Drive_Letter%%HP%\Documents\ /s /y>nul 2>nul
  108. attrib -r -a -s -h %Drive_Letter%%HP%\Documents\desktop.ini>nul 2>nul
  109. echo.>%Drive_Letter%%HP%\Documents\desktop.ini
  110. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Documents\desktop.ini
  111. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21770>>%Drive_Letter%%HP%\Documents\desktop.ini
  112. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-112>>%Drive_Letter%%HP%\Documents\desktop.ini
  113. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%%HP%\Documents\desktop.ini
  114. echo IconIndex=-235>>%Drive_Letter%%HP%\Documents\desktop.ini
  115. attrib -r +a +s +h %Drive_Letter%%HP%\Documents\desktop.ini>nul 2>nul
  116. attrib -r +a +s -h %Drive_Letter%%HP%\Documents /s /d>nul 2>nul
  117. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Personal" /t REG_SZ /d "%Drive_Letter%%HP%\Documents">nul 2>nul
  118. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Personal" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents">nul 2>nul
  119. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{F42EE2D3-909F-4907-8871-4C22FC0BF756}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents">nul 2>nul
  120. if %DelFile% EQU Y rd /s /q %Current_Personal%>nul 2>nul

  121. echo 正在处理『桌面』...
  122. md %Drive_Letter%%HP%\Desktop>nul 2>nul
  123. if %CopyFile% EQU Y xcopy %Current_Desktop%\*.* %Drive_Letter%%HP%\Desktop\ /s /y>nul 2>nul
  124. attrib -r -a -s -h %Drive_Letter%%HP%\Desktop\desktop.ini>nul 2>nul
  125. echo.>%Drive_Letter%%HP%\Desktop\desktop.ini
  126. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Desktop\desktop.ini
  127. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21769>>%Drive_Letter%%HP%\Desktop\desktop.ini
  128. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-183>>%Drive_Letter%%HP%\Desktop\desktop.ini
  129. attrib -r -a +s +h %Drive_Letter%%HP%\Desktop\desktop.ini>nul 2>nul
  130. attrib -r +a +s -h %Drive_Letter%%HP%\Desktop /s /d>nul 2>nul
  131. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Desktop" /t REG_SZ /d "%Drive_Letter%%HP%\Desktop">nul 2>nul
  132. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Desktop" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Desktop">nul 2>nul
  133. if %DelFile% EQU Y rd /s /q %Current_Desktop%>nul 2>nul

  134. echo 正在处理『下载』...
  135. md %Drive_Letter%%HP%\Documents\Downloads>nul 2>nul
  136. if %CopyFile% EQU Y xcopy %Current_Downloads%\*.* %Drive_Letter%%HP%\Documents\Downloads\ /s /y>nul 2>nul
  137. attrib -r -a -s -h %Drive_Letter%%HP%\Documents\Downloads\desktop.ini>nul 2>nul
  138. echo.>%Drive_Letter%%HP%\Documents\Downloads\desktop.ini
  139. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Documents\Downloads\desktop.ini
  140. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21798>>%Drive_Letter%%HP%\Documents\Downloads\desktop.ini
  141. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-184>>%Drive_Letter%%HP%\Documents\Downloads\desktop.ini
  142. attrib -r +a +s +h %Drive_Letter%%HP%\Documents\Downloads\desktop.ini>nul 2>nul
  143. attrib -r +a +s -h %Drive_Letter%%HP%\Documents\Downloads /s /d>nul 2>nul
  144. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{374DE290-123F-4565-9164-39C4925E467B}" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Downloads">nul 2>nul
  145. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{374DE290-123F-4565-9164-39C4925E467B}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Downloads">nul 2>nul
  146. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{7D83EE9B-2244-4E70-B1F5-5393042AF1E4}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Downloads">nul 2>nul
  147. if %DelFile% EQU Y rd /s /q %Current_Downloads%>nul 2>nul

  148. echo 正在处理『收藏夹』...
  149. md %Drive_Letter%%HP%\Favorites>nul 2>nul
  150. if %CopyFile% EQU Y xcopy %Current_Favorites%\*.* %Drive_Letter%%HP%\Favorites\ /s /y>nul 2>nul
  151. attrib -r -a -s -h %Drive_Letter%%HP%\Favorites\desktop.ini>nul 2>nul
  152. echo.>%Drive_Letter%%HP%\Favorites\desktop.ini
  153. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Favorites\desktop.ini
  154. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21796>>%Drive_Letter%%HP%\Favorites\desktop.ini
  155. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-115>>%Drive_Letter%%HP%\Favorites\desktop.ini
  156. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%%HP%\Favorites\desktop.ini
  157. echo IconIndex=-173>>%Drive_Letter%%HP%\Favorites\desktop.ini
  158. attrib -r +a +s +h %Drive_Letter%%HP%\Favorites\desktop.ini>nul 2>nul
  159. attrib -r +a +s -h %Drive_Letter%%HP%\Favorites /s /d>nul 2>nul
  160. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Favorites" /t REG_SZ /d "%Drive_Letter%%HP%\Favorites">nul 2>nul
  161. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Favorites" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Favorites">nul 2>nul
  162. if %DelFile% EQU Y rd /s /q %Current_Favorites%>nul 2>nul

  163. echo 正在处理『我的图片』...
  164. md %Drive_Letter%%HP%\Documents\Pictures>nul 2>nul
  165. if %CopyFile% EQU Y xcopy %Current_My_Pictures%\*.* %Drive_Letter%%HP%\Documents\Pictures\ /s /y>nul 2>nul
  166. attrib -r -a -s -h %Drive_Letter%%HP%\Documents\Pictures\desktop.ini>nul 2>nul
  167. echo.>%Drive_Letter%%HP%\Pictures\desktop.ini
  168. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Documents\Pictures\desktop.ini
  169. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21779>>%Drive_Letter%%HP%\Documents\Pictures\desktop.ini
  170. echo InfoTip=@%%SystemRoot%%\system32\shell32.dll,-12688>>%Drive_Letter%%HP%\Documents\Pictures\desktop.ini
  171. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-113>>%Drive_Letter%%HP%\Documents\Pictures\desktop.ini
  172. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%%HP%\Documents\Pictures\desktop.ini
  173. echo IconIndex=-236>>%Drive_Letter%%HP%\Documents\Pictures\desktop.ini
  174. attrib -r +a +s +h %Drive_Letter%%HP%\Documents\Pictures\desktop.ini>nul 2>nul
  175. attrib -r +a +s -h %Drive_Letter%%HP%\Documents\Pictures /s /d>nul 2>nul
  176. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Pictures" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Pictures">nul 2>nul
  177. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Pictures" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Pictures">nul 2>nul
  178. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{0DDD015D-B06C-45D5-8C4C-F59713854639}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Pictures">nul 2>nul
  179. if %DelFile% EQU Y rd /s /q %Current_My_Pictures%>nul 2>nul

  180. echo 正在处理『我的视频』...
  181. md %Drive_Letter%%HP%\Documents\Videos>nul 2>nul
  182. if %CopyFile% EQU Y xcopy %Current_My_Video%\*.* %Drive_Letter%%HP%\Documents\Videos\ /s /y>nul 2>nul
  183. attrib -r -a -s -h %Drive_Letter%%HP%\Documents\Videos\desktop.ini>nul 2>nul
  184. echo.>%Drive_Letter%%HP%\Documents\Videos\desktop.ini
  185. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Documents\Videos\desktop.ini
  186. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21791>>%Drive_Letter%%HP%\Documents\Videos\desktop.ini
  187. echo InfoTip=@%%SystemRoot%%\system32\shell32.dll,-12690>>%Drive_Letter%%HP%\Documents\Videos\desktop.ini
  188. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-189>>%Drive_Letter%%HP%\Documents\Videos\desktop.ini
  189. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%%HP%\Documents\Videos\desktop.ini
  190. echo IconIndex=-238>>%Drive_Letter%%HP%\Documents\Videos\desktop.ini
  191. attrib -r +a +s +h %Drive_Letter%%HP%\Documents\Videos\desktop.ini>nul 2>nul
  192. attrib -r +a +s -h %Drive_Letter%%HP%\Documents\Videos /s /d>nul 2>nul
  193. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Video" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Videos">nul 2>nul
  194. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Video" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Videos">nul 2>nul
  195. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{35286A68-3C57-41A1-BBB1-0EAE73D76C95}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Videos">nul 2>nul
  196. if %DelFile% EQU Y rd /s /q %Current_My_Video%>nul 2>nul

  197. echo 正在处理『我的音乐』...
  198. md %Drive_Letter%%HP%\Documents\Music>nul 2>nul
  199. if %CopyFile% EQU Y xcopy %Current_My_Music%\*.* %Drive_Letter%%HP%\Documents\Music\ /s /y>nul 2>nul
  200. attrib -r -a -s -h %Drive_Letter%%HP%\Documents\Music\desktop.ini>nul 2>nul
  201. echo.>%Drive_Letter%%HP%\Documents\Music\desktop.ini
  202. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Documents\Music\desktop.ini
  203. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21790>>%Drive_Letter%%HP%\Documents\Music\desktop.ini
  204. echo InfoTip=@%%SystemRoot%%\system32\shell32.dll,-12689>>%Drive_Letter%%HP%\Documents\Music\desktop.ini
  205. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-108>>%Drive_Letter%%HP%\Documents\Music\desktop.ini
  206. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%%HP%\Documents\Music\desktop.ini
  207. echo IconIndex=-237>>%Drive_Letter%%HP%\Documents\Music\desktop.ini
  208. attrib -r +a +s +h %Drive_Letter%%HP%\Documents\Music\desktop.ini>nul 2>nul
  209. attrib -r +a +s -h %Drive_Letter%%HP%\Documents\Music /s /d>nul 2>nul
  210. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Music" /t REG_SZ /d "%Drive_Letter%%HP%\Documents\Music">nul 2>nul
  211. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Music" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Music">nul 2>nul
  212. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{A0C69A99-21C8-4671-8703-7934162FCF1D}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Documents\Music">nul 2>nul
  213. if %DelFile% EQU Y rd /s /q %Current_My_Music%>nul 2>nul

  214. echo 正在处理『保存的游戏』...
  215. md %Drive_Letter%%HP%"Saved Games">nul 2>nul
  216. if %CopyFile% EQU Y xcopy "%Current_Saved_Games%\*.*" %Drive_Letter%%HP%"Saved Games"\ /s /y>nul 2>nul
  217. attrib -r -a -s -h %Drive_Letter%%HP%"Saved Games"\desktop.ini>nul 2>nul
  218. echo.>%Drive_Letter%%HP%"Saved Games"\desktop.ini
  219. echo [.ShellClassInfo]>>%Drive_Letter%%HP%"Saved Games"\desktop.ini
  220. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21814>>%Drive_Letter%%HP%"Saved Games"\desktop.ini
  221. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-186>>%Drive_Letter%%HP%"Saved Games"\desktop.ini
  222. attrib -r +a +s +h %Drive_Letter%%HP%"Saved Games"\desktop.ini>nul 2>nul
  223. attrib -r +a +s -h %Drive_Letter%%HP%"Saved Games" /s /d>nul 2>nul
  224. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{4C5C32FF-BB9D-43B0-B5B4-2D72E54EAAA4}" /t REG_SZ /d "%Drive_Letter%%HP%\Saved Games">nul 2>nul
  225. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{4C5C32FF-BB9D-43B0-B5B4-2D72E54EAAA4}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Saved Games">nul 2>nul
  226. if %DelFile% EQU Y rd /s /q "%Current_Saved_Games%">nul 2>nul

  227. echo 正在处理『联系人』...
  228. md %Drive_Letter%%HP%\Contacts>nul 2>nul
  229. if %CopyFile% EQU Y xcopy %Current_Contacts%\*.* %Drive_Letter%%HP%\Contacts\ /s /y>nul 2>nul
  230. attrib -r -a -s -h %Drive_Letter%%HP%\Contacts\desktop.ini>nul 2>nul
  231. echo.>%Drive_Letter%%HP%\Contacts\desktop.ini
  232. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Contacts\desktop.ini
  233. echo LocalizedResourceName=@%%CommonProgramFiles%%\system\wab32res.dll,-10100>>%Drive_Letter%%HP%\Contacts\desktop.ini
  234. echo InfoTip=@%%CommonProgramFiles%%\system\wab32res.dll,-10200>>%Drive_Letter%%HP%\Contacts\desktop.ini
  235. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-181>>%Drive_Letter%%HP%\Contacts\desktop.ini
  236. attrib -r +a +s +h %Drive_Letter%%HP%\Contacts\desktop.ini>nul 2>nul
  237. attrib -r +a +s -h %Drive_Letter%%HP%\Contacts /s /d>nul 2>nul
  238. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{56784854-C6CB-462B-8169-88E350ACB882}" /t REG_SZ /d "%Drive_Letter%%HP%\Contacts">nul 2>nul
  239. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{56784854-C6CB-462B-8169-88E350ACB882}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Contacts">nul 2>nul
  240. if %DelFile% EQU Y rd /s /q %Current_Contacts%>nul 2>nul

  241. echo 正在处理『链接』...
  242. md %Drive_Letter%%HP%\Links>nul 2>nul
  243. if %CopyFile% EQU Y xcopy %Current_Links%\*.* %Drive_Letter%%HP%\Links\ /s /y>nul 2>nul
  244. attrib -r -a -s -h %Drive_Letter%%HP%\Links\desktop.ini>nul 2>nul
  245. echo.>%Drive_Letter%%HP%\Links\desktop.ini
  246. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Links\desktop.ini
  247. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21810>>%Drive_Letter%%HP%\Links\desktop.ini
  248. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-185>>%Drive_Letter%%HP%\Links\desktop.ini
  249. echo DefaultDropEffect=^4>>%Drive_Letter%%HP%\Links\desktop.ini
  250. echo [LocalizedFileNames]>>%Drive_Letter%%HP%\Links\desktop.ini
  251. echo RecentPlaces.lnk=@shell32.dll,-37217>>%Drive_Letter%%HP%\Links\desktop.ini
  252. echo Desktop.lnk=@shell32.dll,-21769>>%Drive_Letter%%HP%\Links\desktop.ini
  253. echo Downloads.lnk=@shell32.dll,-21798>>%Drive_Letter%%HP%\Links\desktop.ini
  254. attrib -r +a +s +h %Drive_Letter%%HP%\Links\desktop.ini>nul 2>nul
  255. attrib -r +a +s -h %Drive_Letter%%HP%\Links /s /d>nul 2>nul
  256. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{BFB9D5E0-C6A9-404C-B2B2-AE6DB6AF4968}" /t REG_SZ /d "%Drive_Letter%%HP%\Links">nul 2>nul
  257. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{BFB9D5E0-C6A9-404C-B2B2-AE6DB6AF4968}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Links">nul 2>nul
  258. if %DelFile% EQU Y rd /s /q %Current_Links%>nul 2>nul

  259. echo 正在处理『搜索』...
  260. md %Drive_Letter%%HP%\Searches>nul 2>nul
  261. if %CopyFile% EQU Y xcopy %Current_Searches%\*.* %Drive_Letter%%HP%\Searches\ /s /y>nul 2>nul
  262. attrib -r -a -s -h %Drive_Letter%%HP%\Searches\desktop.ini>nul 2>nul
  263. echo.>%Drive_Letter%%HP%\Searches\desktop.ini
  264. echo [.ShellClassInfo]>>%Drive_Letter%%HP%\Searches\desktop.ini
  265. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-9031>>%Drive_Letter%%HP%\Searches\desktop.ini
  266. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-18>>%Drive_Letter%%HP%\Searches\desktop.ini
  267. echo [LocalizedFileNames]>>%Drive_Letter%%HP%\Searches\desktop.ini
  268. echo Indexed Locations.search-ms=@searchfolder.dll,-32820>>%Drive_Letter%%HP%\Searches\desktop.ini
  269. echo Everywhere.search-ms=@searchfolder.dll,-32822>>%Drive_Letter%%HP%\Searches\desktop.ini
  270. attrib -r +a +s +h %Drive_Letter%%HP%\Searches\desktop.ini>nul 2>nul
  271. attrib -r +a +s -h %Drive_Letter%%HP%\Searches /s /d>nul 2>nul
  272. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{7D1D3A04-DEBB-4115-95CF-2F29DA2920DA}" /t REG_SZ /d "%Drive_Letter%%HP%\Searches">nul 2>nul
  273. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{7D1D3A04-DEBB-4115-95CF-2F29DA2920DA}" /t REG_EXPAND_SZ /d "%Drive_Letter%%HP%\Searches">nul 2>nul
  274. if %DelFile% EQU Y rd /s /q %Current_Searches%>nul 2>nul

  275. rem 正在处理『MediaPlayer』...
  276. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences" /f /v "TrackFoldersDirectories0" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Music">nul 2>nul
  277. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences" /f /v "TrackFoldersDirectories1" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Pictures">nul 2>nul
  278. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences" /f /v "TrackFoldersDirectories2" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Videos">nul 2>nul
  279. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences\HME\LastSharedFolders" /f /v "Folders0" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Music">nul 2>nul
  280. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences\HME\LastSharedFolders" /f /v "Folders1" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Pictures">nul 2>nul
  281. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences\HME\LastSharedFolders" /f /v "Folders2" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Videos">nul 2>nul

  282. rem 正在处理『图标缓存』...
  283. attrib -r -a -s -h "%USERPROFILE%\Local Settings\Application Data\IconCache.db">nul 2>nul
  284. del /f /q "%USERPROFILE%\Local Settings\Application Data\IconCache.db">nul 2>nul
  285. taskkill /f /im explorer.exe
  286. start explorer.exe
  287. goto end

  288. :default
  289. echo ================================= 还原默认值 ==================================
  290. echo 目标驱动器:%USERPROFILE%
  291. echo 复制文件夹:%CopyFile%
  292. echo 删除源文件:%DelFile%
  293. echo ===============================================================================
  294. echo.&&pause&&echo.
  295. set Drive_Letter=%HOMEDRIVE%
  296. echo 正在处理『我的文档』...
  297. md %Drive_Letter%\Users\%USERNAME%\Documents>nul 2>nul
  298. if %CopyFile% EQU Y xcopy %Current_Personal%\*.* %Drive_Letter%\Users\%USERNAME%\Documents\ /s /y>nul 2>nul
  299. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini>nul 2>nul
  300. echo.>%Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini
  301. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini
  302. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21770>>%Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini
  303. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-112>>%Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini
  304. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini
  305. echo IconIndex=-235>>%Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini
  306. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Documents\desktop.ini>nul 2>nul
  307. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Documents /s /d>nul 2>nul
  308. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Personal" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Documents">nul 2>nul
  309. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Personal" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Documents">nul 2>nul
  310. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{F42EE2D3-909F-4907-8871-4C22FC0BF756}" /t REG_EXPAND_SZ /d "%Drive_Letter%\Users\%USERNAME%\Documents">nul 2>nul
  311. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Personal%">nul 2>nul

  312. echo 正在处理『桌面』...
  313. md %Drive_Letter%\Users\%USERNAME%\Desktop>nul 2>nul
  314. if %CopyFile% EQU Y xcopy %Current_Desktop%\*.* %Drive_Letter%\Users\%USERNAME%\Desktop\ /s /y>nul 2>nul
  315. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Desktop\desktop.ini>nul 2>nul
  316. echo.>%Drive_Letter%\Users\%USERNAME%\Desktop\desktop.ini
  317. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Desktop\desktop.ini
  318. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21769>>%Drive_Letter%\Users\%USERNAME%\Desktop\desktop.ini
  319. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-183>>%Drive_Letter%\Users\%USERNAME%\Desktop\desktop.ini
  320. attrib -r -a +s +h %Drive_Letter%\Users\%USERNAME%\Desktop\desktop.ini>nul 2>nul
  321. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Desktop /s /d>nul 2>nul
  322. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Desktop" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Desktop">nul 2>nul
  323. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Desktop" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Desktop">nul 2>nul
  324. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Desktop%">nul 2>nul

  325. echo 正在处理『下载』...
  326. md %Drive_Letter%\Users\%USERNAME%\Downloads>nul 2>nul
  327. if %CopyFile% EQU Y xcopy %Current_Downloads%\*.* %Drive_Letter%\Users\%USERNAME%\Downloads\ /s /y>nul 2>nul
  328. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Downloads\desktop.ini>nul 2>nul
  329. echo.>%Drive_Letter%\Users\%USERNAME%\Downloads\desktop.ini
  330. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Downloads\desktop.ini
  331. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21798>>%Drive_Letter%\Users\%USERNAME%\Downloads\desktop.ini
  332. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-184>>%Drive_Letter%\Users\%USERNAME%\Downloads\desktop.ini
  333. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Downloads\desktop.ini>nul 2>nul
  334. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Downloads /s /d>nul 2>nul
  335. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{374DE290-123F-4565-9164-39C4925E467B}" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Downloads">nul 2>nul
  336. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{374DE290-123F-4565-9164-39C4925E467B}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Downloads">nul 2>nul
  337. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{7D83EE9B-2244-4E70-B1F5-5393042AF1E4}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Downloads">nul 2>nul
  338. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Downloads%">nul 2>nul

  339. echo 正在处理『收藏夹』...
  340. md %Drive_Letter%\Users\%USERNAME%\Favorites>nul 2>nul
  341. if %CopyFile% EQU Y xcopy %Current_Favorites%\*.* %Drive_Letter%\Users\%USERNAME%\Favorites\ /s /y>nul 2>nul
  342. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini>nul 2>nul
  343. echo.>%Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini
  344. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini
  345. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21796>>%Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini
  346. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-115>>%Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini
  347. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini
  348. echo IconIndex=-173>>%Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini
  349. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Favorites\desktop.ini>nul 2>nul
  350. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Favorites /s /d>nul 2>nul
  351. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "Favorites" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Favorites">nul 2>nul
  352. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "Favorites" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Favorites">nul 2>nul
  353. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Favorites%">nul 2>nul

  354. echo 正在处理『我的图片』...
  355. md %Drive_Letter%\Users\%USERNAME%\Pictures>nul 2>nul
  356. if %CopyFile% EQU Y xcopy %Current_My_Pictures%\*.* %Drive_Letter%\Users\%USERNAME%\Pictures\ /s /y>nul 2>nul
  357. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini>nul 2>nul
  358. echo.>%Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini
  359. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini
  360. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21779>>%Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini
  361. echo InfoTip=@%%SystemRoot%%\system32\shell32.dll,-12688>>%Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini
  362. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-113>>%Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini
  363. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini
  364. echo IconIndex=-236>>%Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini
  365. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Pictures\desktop.ini>nul 2>nul
  366. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Pictures /s /d>nul 2>nul
  367. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Pictures" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Pictures">nul 2>nul
  368. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Pictures" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Pictures">nul 2>nul
  369. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{0DDD015D-B06C-45D5-8C4C-F59713854639}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Pictures">nul 2>nul
  370. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_My_Pictures%">nul 2>nul

  371. echo 正在处理『我的视频』...
  372. md %Drive_Letter%\Users\%USERNAME%\Videos>nul 2>nul
  373. if %CopyFile% EQU Y xcopy %Current_My_Video%\*.* %Drive_Letter%\Users\%USERNAME%\Videos\ /s /y>nul 2>nul
  374. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini>nul 2>nul
  375. echo.>%Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini
  376. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini
  377. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21791>>%Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini
  378. echo InfoTip=@%%SystemRoot%%\system32\shell32.dll,-12690>>%Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini
  379. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-189>>%Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini
  380. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini
  381. echo IconIndex=-238>>%Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini
  382. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Videos\desktop.ini>nul 2>nul
  383. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Videos /s /d>nul 2>nul
  384. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Video" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Videos">nul 2>nul
  385. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Video" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Videos">nul 2>nul
  386. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{35286A68-3C57-41A1-BBB1-0EAE73D76C95}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Videos">nul 2>nul
  387. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_My_Video%">nul 2>nul

  388. echo 正在处理『我的音乐』...
  389. md %Drive_Letter%\Users\%USERNAME%\Music>nul 2>nul
  390. if %CopyFile% EQU Y xcopy %Current_My_Music%\*.* %Drive_Letter%\Users\%USERNAME%\Music\ /s /y>nul 2>nul
  391. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Music\desktop.ini>nul 2>nul
  392. echo.>%Drive_Letter%\Users\%USERNAME%\Music\desktop.ini
  393. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Music\desktop.ini
  394. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21790>>%Drive_Letter%\Users\%USERNAME%\Music\desktop.ini
  395. echo InfoTip=@%%SystemRoot%%\system32\shell32.dll,-12689>>%Drive_Letter%\Users\%USERNAME%\Music\desktop.ini
  396. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-108>>%Drive_Letter%\Users\%USERNAME%\Music\desktop.ini
  397. echo IconFile=%%SystemRoot%%\system32\shell32.dll>>%Drive_Letter%\Users\%USERNAME%\Music\desktop.ini
  398. echo IconIndex=-237>>%Drive_Letter%\Users\%USERNAME%\Music\desktop.ini
  399. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Music\desktop.ini>nul 2>nul
  400. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Music /s /d>nul 2>nul
  401. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "My Music" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Music">nul 2>nul
  402. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "My Music" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Music">nul 2>nul
  403. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{A0C69A99-21C8-4671-8703-7934162FCF1D}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Music">nul 2>nul
  404. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_My_Music%">nul 2>nul

  405. echo 正在处理『保存的游戏』...
  406. md %Drive_Letter%\Users\%USERNAME%"Saved Games">nul 2>nul
  407. if %CopyFile% EQU Y xcopy "%Current_Saved_Games%\*.*" %Drive_Letter%\Users\%USERNAME%"Saved Games"\ /s /y>nul 2>nul
  408. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%"Saved Games"\desktop.ini>nul 2>nul
  409. echo.>%Drive_Letter%\Users\%USERNAME%"Saved Games"\desktop.ini
  410. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%"Saved Games"\desktop.ini
  411. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21814>>%Drive_Letter%\Users\%USERNAME%"Saved Games"\desktop.ini
  412. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-186>>%Drive_Letter%\Users\%USERNAME%"Saved Games"\desktop.ini
  413. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%"Saved Games"\desktop.ini>nul 2>nul
  414. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%"Saved Games" /s /d>nul 2>nul
  415. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{4C5C32FF-BB9D-43B0-B5B4-2D72E54EAAA4}" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Saved Games">nul 2>nul
  416. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{4C5C32FF-BB9D-43B0-B5B4-2D72E54EAAA4}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Saved Games">nul 2>nul
  417. if %select% NEQ U if %DelFile% EQU Y rd /s /q "%Current_Saved_Games%">nul 2>nul

  418. echo 正在处理『联系人』...
  419. md %Drive_Letter%\Users\%USERNAME%\Contacts>nul 2>nul
  420. if %CopyFile% EQU Y xcopy %Current_Contacts%\*.* %Drive_Letter%\Users\%USERNAME%\Contacts\ /s /y>nul 2>nul
  421. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Contacts\desktop.ini>nul 2>nul
  422. echo.>%Drive_Letter%\Users\%USERNAME%\Contacts\desktop.ini
  423. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Contacts\desktop.ini
  424. echo LocalizedResourceName=@%%CommonProgramFiles%%\system\wab32res.dll,-10100>>%Drive_Letter%\Users\%USERNAME%\Contacts\desktop.ini
  425. echo InfoTip=@%%CommonProgramFiles%%\system\wab32res.dll,-10200>>%Drive_Letter%\Users\%USERNAME%\Contacts\desktop.ini
  426. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-181>>%Drive_Letter%\Users\%USERNAME%\Contacts\desktop.ini
  427. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Contacts\desktop.ini>nul 2>nul
  428. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Contacts /s /d>nul 2>nul
  429. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{56784854-C6CB-462B-8169-88E350ACB882}" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Contacts">nul 2>nul
  430. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{56784854-C6CB-462B-8169-88E350ACB882}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Contacts">nul 2>nul
  431. if %select% NEQ U if %DelFile% EQU Y rd /s /q %Current_Contacts%>nul 2>nul

  432. echo 正在处理『链接』...
  433. md %Drive_Letter%\Users\%USERNAME%\Links>nul 2>nul
  434. if %CopyFile% EQU Y xcopy %Current_Links%\*.* %Drive_Letter%\Users\%USERNAME%\Links\ /s /y>nul 2>nul
  435. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Links\desktop.ini>nul 2>nul
  436. echo.>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  437. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  438. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-21810>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  439. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-185>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  440. echo DefaultDropEffect=^4>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  441. echo [LocalizedFileNames]>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  442. echo RecentPlaces.lnk=@shell32.dll,-37217>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  443. echo Desktop.lnk=@shell32.dll,-21769>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  444. echo Downloads.lnk=@shell32.dll,-21798>>%Drive_Letter%\Users\%USERNAME%\Links\desktop.ini
  445. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Links\desktop.ini>nul 2>nul
  446. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Links /s /d>nul 2>nul
  447. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{BFB9D5E0-C6A9-404C-B2B2-AE6DB6AF4968}" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Links">nul 2>nul
  448. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{BFB9D5E0-C6A9-404C-B2B2-AE6DB6AF4968}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Links">nul 2>nul
  449. if %select% NEQ U if %DelFile% EQU Y rd /s /q %Current_Links%>nul 2>nul

  450. echo 正在处理『搜索』...
  451. md %Drive_Letter%\Users\%USERNAME%\Searches>nul 2>nul
  452. if %CopyFile% EQU Y xcopy %Current_Searches%\*.* %Drive_Letter%\Users\%USERNAME%\Searches\ /s /y>nul 2>nul
  453. attrib -r -a -s -h %Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini>nul 2>nul
  454. echo.>%Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini
  455. echo [.ShellClassInfo]>>%Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini
  456. echo LocalizedResourceName=@%%SystemRoot%%\system32\shell32.dll,-9031>>%Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini
  457. echo IconResource=%%SystemRoot%%\system32\imageres.dll,-18>>%Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini
  458. echo [LocalizedFileNames]>>%Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini
  459. echo Indexed Locations.search-ms=@searchfolder.dll,-32820>>%Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini
  460. echo Everywhere.search-ms=@searchfolder.dll,-32822>>%Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini
  461. attrib -r +a +s +h %Drive_Letter%\Users\%USERNAME%\Searches\desktop.ini>nul 2>nul
  462. attrib -r +a +s -h %Drive_Letter%\Users\%USERNAME%\Searches /s /d>nul 2>nul
  463. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /f /v "{7D1D3A04-DEBB-4115-95CF-2F29DA2920DA}" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Searches">nul 2>nul
  464. reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" /f /v "{7D1D3A04-DEBB-4115-95CF-2F29DA2920DA}" /t REG_EXPAND_SZ /d "%%USERPROFILE%%\Searches">nul 2>nul
  465. if %select% NEQ U if %DelFile% EQU Y rd /s /q %Current_Searches%>nul 2>nul

  466. rem 正在处理『MediaPlayer』...
  467. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences" /f /v "TrackFoldersDirectories0" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Music">nul 2>nul
  468. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences" /f /v "TrackFoldersDirectories1" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Pictures">nul 2>nul
  469. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences" /f /v "TrackFoldersDirectories2" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Videos">nul 2>nul
  470. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences\HME\LastSharedFolders" /f /v "Folders0" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Music">nul 2>nul
  471. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences\HME\LastSharedFolders" /f /v "Folders1" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Pictures">nul 2>nul
  472. reg add "HKCU\Software\Microsoft\MediaPlayer\Preferences\HME\LastSharedFolders" /f /v "Folders2" /t REG_SZ /d "%Drive_Letter%\Users\%USERNAME%\Videos">nul 2>nul

  473. rem 正在处理『图标缓存』...
  474. attrib -r -a -s -h "%USERPROFILE%\AppData\Local\IconCache.db">nul 2>nul
  475. del /f /q "%USERPROFILE%\AppData\Local\IconCache.db">nul 2>nul
  476. taskkill /f /im explorer.exe
  477. start explorer.exe
  478. goto end

  479. :help
  480. echo 移动目标文件夹位置
  481. echo.
  482. echo  %~n0 [drive:] [/U] [/Q] [/H]
  483. echo.
  484. echo   drive:  目标驱动器
  485. echo   /U      还原默认值
  486. echo   /Q      退出向导
  487. echo   /H      显示帮助
  488. echo.
  489. echo 命令行键入 %~n0,可以启动一个向导。
  490. echo.
  491. if "%1"=="" pause&&goto input

  492. :end
  493. set drive=
  494. set choice=
  495. set select=
  496. set Drive_Letter=
  497. set Current_Personal=
  498. set Current_Desktop=
  499. set Current_Downloads=
  500. set Current_Favorites=
  501. set Current_My_Pictures=
  502. set Current_My_Video=
  503. set Current_My_Music=
  504. set h=
复制代码

点评

2楼的是最终版么???  详情 回复 发表于 2017-12-5 10:20

评分

参与人数 1无忧币 +5 收起 理由
wuhuyou + 5 很给力!

查看全部评分

回复

使用道具 举报

4#
发表于 2017-12-4 07:02:20 来自手机 | 只看该作者
合并,开头加个系统判断。
回复

使用道具 举报

5#
发表于 2017-12-4 07:15:44 | 只看该作者
感谢分享了 好好好
回复

使用道具 举报

6#
发表于 2017-12-4 09:06:21 | 只看该作者
非常强大,谢谢分享。
回复

使用道具 举报

7#
发表于 2017-12-4 09:07:22 来自手机 | 只看该作者
真够长的
回复

使用道具 举报

8#
 楼主| 发表于 2017-12-4 13:25:03 | 只看该作者
此批处理是排除存在Windows系统安装文件夹的,查看11行和13行,可自己调整!
回复

使用道具 举报

9#
发表于 2017-12-4 15:10:51 | 只看该作者
合并起来就更好了,感谢分享,很有用的工具
回复

使用道具 举报

10#
发表于 2017-12-5 07:08:20 | 只看该作者
谢谢,学习一下
回复

使用道具 举报

11#
发表于 2017-12-5 10:20:12 | 只看该作者

2楼的是最终版么???

点评

2楼适用Win7以上系统  详情 回复 发表于 2017-12-5 15:10
回复

使用道具 举报

12#
 楼主| 发表于 2017-12-5 15:10:28 | 只看该作者
boy6585948 发表于 2017-12-5 10:20
2楼的是最终版么???

2楼适用Win7以上系统

点评

好的,谢谢LZ!!!  详情 回复 发表于 2017-12-6 07:18
回复

使用道具 举报

13#
发表于 2017-12-5 17:07:29 | 只看该作者
谢谢,学习了
回复

使用道具 举报

14#
发表于 2017-12-6 07:18:10 | 只看该作者
chishingchan 发表于 2017-12-5 15:10
2楼适用Win7以上系统

好的,谢谢LZ!!!
回复

使用道具 举报

15#
发表于 2017-12-7 14:53:45 | 只看该作者
谢谢楼主分享~
回复

使用道具 举报

16#
发表于 2017-12-12 17:30:50 | 只看该作者
谢谢楼主分享
回复

使用道具 举报

17#
发表于 2018-1-2 14:42:07 | 只看该作者
很给力哦
回复

使用道具 举报

18#
发表于 2018-1-2 15:33:15 | 只看该作者
非常给力,感谢分享。
回复

使用道具 举报

19#
发表于 2018-1-18 17:37:44 | 只看该作者
本帖最后由 1904860494 于 2018-1-18 17:38 编辑

能不能做个批处理,就是将系统盘保留100,剩余硬盘空间均匀分3个分区,如果有固态,自动将系统迁移到固态,因为出厂的电脑所有分区都是合在一起的,因为我是做电脑的,手动太费事。。。。。。
回复

使用道具 举报

20#
发表于 2020-3-7 11:55:54 | 只看该作者
我用wmic,shell.application的movehere,在XP测试能通过,但win7部分设置通过,win10居然大部分不能通过,原因未知,放弃了
回复

使用道具 举报

21#
发表于 2020-3-7 12:00:24 | 只看该作者
批处理节省了体力啊
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|捐助支持|无忧启动 ( 闽ICP备05002490号-1 )

闽公网安备 35020302032614号

GMT+8, 2024-11-28 06:47

Powered by Discuz! X3.3

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表