Advertisement
Guest User

wowmaint.bat

a guest
Jul 12th, 2019
224
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.65 KB | None | 0 0
  1. set $doc=D:\Games\WoW\Backup
  2. set $pic=D:\Games\WoW\Backup
  3. setlocal enableDelayedExpansion
  4. tasklist | findstr /i /c:"wow.exe" /c:"wow-64.exe"
  5. if %errorlevel% equ 0 exit
  6. cd /d "%~dp0Logs"
  7. if not exist WoWChatLog.txt goto combat
  8. for %%S in (WoWChatLog.txt) do if %%~zS equ 0 type nul > WoWChatLog.txt & del /f /q WoWChatLog.txt & goto combat
  9. for /f %%C in ('dir /b WoWChatLog*.txt ^| find /c /v ""') do set $num=%%C
  10. if %$num% geq 10 type nul > WoWChatLog1.txt & del /f /q WoWChatLog1.txt
  11. set $count=0
  12. for /f "tokens=*" %%T in ('dir /b /o:d WoWChatLog*.txt') do (
  13. set /a $count+=1
  14. ren %%T WoWChatLog!$count!.txt)
  15. :combat
  16. if not exist WoWCombatLog.txt goto taint
  17. for %%S in (WoWCombatLog.txt) do if %%~zS equ 0 type nul > WoWCombatLog.txt & del /f /q WoWCombatLog.txt & goto taint
  18. for /f %%C in ('dir /b WoWCombatLog*.txt ^| find /c /v ""') do set $num=%%C
  19. if %$num% geq 10 type nul > WoWCombatLog1.txt & del /f /q WoWCombatLog1.txt
  20. set $count=0
  21. for /f "tokens=*" %%T in ('dir /b /o:d WoWCombatLog*.txt') do (
  22. set /a $count+=1
  23. ren %%T WoWCombatLog!$count!.txt)
  24. :taint
  25. if not exist taint.log goto files
  26. for %%S in (taint.log) do if %%~zS equ 0 type nul > taint.log & del /f /q taint.log & goto files
  27. for /f %%C in ('dir /b taint*.log ^| find /c /v ""') do set $num=%%C
  28. if %$num% geq 10 type nul > taint1.log & del /f /q taint1.log
  29. set $count=0
  30. for /f "tokens=*" %%T in ('dir /b /o:d taint*.log') do (
  31. set /a $count+=1
  32. ren %%T taint!$count!.log)
  33. :files
  34. robocopy "%~dp0." "%$doc%\WoW other" *.bat
  35. robocopy "%~dp0Fonts" "%$doc%\WoW other\Fonts" /E
  36. robocopy "%~dp0Logs" "%$doc%\WoW logs" WoW*Log*.txt
  37. robocopy "%~dp0Logs" "%$doc%\WoW logs" taint*.log
  38. robocopy "%~dp0Screenshots" "%$pic%\WoW screenshots"
  39. robocopy "%~dp0Sound" "%$doc%\WoW other\Sound" /E
  40. robocopy "%$doc%\WoW logs" "%~dp0Logs" WoW*Log*.txt
  41. robocopy "%$doc%\WoW logs" "%~dp0Logs" taint*.log
  42. robocopy "%$doc%\WoW other" "%~dp0." *.bat
  43. robocopy "%$doc%\WoW other\Fonts" "%~dp0Fonts" /E
  44. robocopy "%$doc%\WoW other\Sound" "%~dp0Sound" /E
  45. robocopy "%$pic%\WoW screenshots" "%~dp0Screenshots"
  46. cd /d "%$doc%\WoW Interface"
  47. md Interface
  48. for /f %%C in ('dir /b Interface* ^| find /c /v ""') do set $num=%%C
  49. if %$num% geq 10 rd /s /q Interface1
  50. set $count=0
  51. for /f "tokens=*" %%T in ('dir /b /o:d Interface*') do (
  52. set /a $count+=1
  53. ren %%T Interface!$count!)
  54. robocopy "%~dp0Interface" "%$doc%\WoW Interface\Interface%$count%" /E
  55. cd /d "%$doc%\WoW WTF"
  56. md WTF
  57. for /f %%C in ('dir /b WTF* ^| find /c /v ""') do set $num=%%C
  58. if %$num% geq 10 rd /s /q WTF1
  59. set $count=0
  60. for /f "tokens=*" %%T in ('dir /b /o:d WTF*') do (
  61. set /a $count+=1
  62. ren %%T WTF!$count!)
  63. robocopy "%~dp0WTF" "%$doc%\WoW WTF\WTF%$count%" /E
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement