Advertisement
GlobalAccessSoftware

copy_control.bat

Nov 16th, 2023
733
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Batch 4.43 KB | Software | 0 0
  1.  
  2.  
  3. ::: RC8
  4.  
  5. ::::::::::::::::::::::::::::::::::::::::::::::::::::::
  6. :: Split from AAA-Sync.bat v7.9.4.42 20220921044322
  7. :: v7.9.7.71 20221108222021 by -JpE-
  8. :: The WorkHorse Master Controller!!! ::
  9. ::::::::::::::::::::::::::::::::::::::::::::::::::::::
  10.   if not defined vers set vers=v8.5.5.67 20230630032014 by -JpE-
  11.  
  12. set cops="%bats%\copy_backups.bat"
  13. set play="%bats%\playlist_backups.bat"
  14.  
  15. set /a round=0
  16. if %r3v3rs3% equ 2 if %backout% equ 0 goto main
  17.  
  18. if not exist %play% echo .
  19. if not exist %play% echo %sl%
  20. if not exist %play% echo           *** Playlist Program NOT Found. ***
  21. if not exist %play% echo %sl%
  22. if not exist %play% echo .
  23. if not exist %play% goto main
  24. ::
  25. REM echo . & echo Before call to play. & echo . & pause & echo .
  26. call %play%
  27.  
  28.  
  29. :main
  30. title "Copy Control Ultra Pro Deluxe: %vers%"
  31. echo %vers%
  32. set /a where=0
  33. if not exist %cops% echo .
  34. if not exist %cops% echo %sl%
  35. if not exist %cops% echo            *** Copies Program NOT Found. ***
  36. if not exist %cops% echo %sl%
  37. if not exist %cops% echo .
  38. if not exist %cops% set /a where=6
  39. if not exist %cops% goto err
  40.  
  41. :: exit2 is reset every time copies is called, wipe is reset whenever get_wipe is called from there.
  42.  
  43.  
  44. :documents
  45. set oper=Documents
  46. set src="C:\Users\%username%\%oper%"
  47. set dcs=My %oper%
  48. set cps="D:\Copies\%dcs%"
  49. set bk1="I:\Copies\%dcs%"
  50. set bk2="X:\%username%-PC\%dcs%"
  51. set bk3="H:\%dcs%"
  52. set bk4="U:\Copies\%dcs%"
  53. ::
  54. call %cops%
  55. ::
  56. if %exit2% equ 4 if %wipe% equ 3 goto reco2
  57. ::  ^   ^ newer fork, call, & handler ^   ^
  58. :: rote mods when D: is locked or other error
  59. :: though it is now coded to differentiate those
  60. :: which is done in the errr module.
  61. if %exit2% equ 4 if %wipe% equ 4 goto pictures
  62.  
  63. if %exit2% gtr 0 set /a where=1
  64. if %exit2% gtr 0 goto err
  65.  
  66.  
  67. :pictures
  68. set oper=Pictures
  69. set src="C:\Users\%username%\%oper%"
  70. set dcs=My %oper%
  71. set cps="D:\Copies\%dcs%"
  72. set bk1="I:\Copies\%dcs%"
  73. set bk2="X:\%username%-PC\%dcs%"
  74. set bk3="H:\%dcs%"
  75. set bk4="U:\Copies\%dcs%"
  76. ::
  77. call %cops%
  78. ::
  79. if %exit2% gtr 2 if %wipe% equ 4 goto favorites
  80. if %exit2% gtr 0 set /a where=2
  81. if %exit2% gtr 0 goto err
  82.  
  83.  
  84. :favorites
  85. set oper=Favorites
  86. set src="C:\Users\%username%\%oper%"
  87. set dcs=My %oper%
  88. set cps="D:\Copies\%dcs%"
  89. set bk1="I:\Copies\%dcs%"
  90. set bk2="X:\%username%-PC\%dcs%"
  91. set bk3="H:\%dcs%"
  92. set bk4="U:\Copies\%dcs%"
  93. ::
  94. call %cops%
  95. ::
  96. if %exit2% gtr 2 if %wipe% equ 4 goto downloads
  97. if %exit2% gtr 0 set /a where=3
  98. if %exit2% gtr 0 goto err
  99.  
  100.  
  101. :downloads
  102. set oper=Downloads
  103. set src="C:\Users\%username%\%oper%"
  104. set dcs=My %oper%
  105. set cps="D:\Copies\%dcs%"
  106. set bk1="I:\Copies\%dcs%"
  107. set bk2="X:\%username%-PC\%dcs%"
  108. set bk3="H:\%dcs%"
  109. set bk4="U:\Copies\%dcs%"
  110. ::
  111. call %cops%
  112. ::
  113. if %exit2% gtr 2 if %wipe% equ 4 goto desktop
  114. if %exit2% gtr 0 set /a where=4
  115. if %exit2% gtr 0 goto err
  116.  
  117.  
  118. :desktop
  119. title ***** Desktop Backups Ultra Deluxe Pro *****
  120. set oper=Desktop
  121. set src="C:\Users\%username%\%oper%"
  122. set dcs=My %oper%
  123. set cps="D:\Copies\%dcs%"
  124. set bk1="I:\Copies\%dcs%"
  125. set bk2="X:\%username%-PC\%dcs%"
  126. set bk3="H:\%dcs%"
  127. set bk4="U:\Copies\%dcs%"
  128. ::
  129. call %cops%
  130. ::
  131. title %mstr%
  132.  
  133. :: NEWER FixX testwell with D: locked though.
  134. if %exit2% gtr 2 if %wipe% equ 4 goto next
  135. if %exit2% gtr 0 set /a where=5
  136. ::
  137. if %exit2% gtr 0 if %where% neq 5 goto err
  138. if %exit2% equ 5 if %where% equ 5 set /a sgnl=4
  139. if %exit2% equ 6 set /a sgnl=3
  140.  
  141. if %sgnl% equ 3 goto return
  142. if %sgnl% equ 4 goto return
  143.  
  144. set txt=backed up.
  145. if %r3v3rs3% equ 2 set txt=RESTORED!
  146. echo %l1%
  147. echo .
  148. echo %sl%
  149. echo           **** Everything Is fully %txt% ****
  150. echo %sl%
  151. echo .
  152. echo %l2%
  153.  
  154.  
  155. :next
  156. if %r3v3rs3% equ 2 set /a sgnl=2
  157. if %r3v3rs3% neq 2 if %backout% equ 1 set /a sgnl=1
  158. if %sgnl% equ 0 set /a sgnl=3
  159. :: i.e. goto exit2
  160. goto return
  161.  
  162.  
  163. :: Exception Handling, see the errr module.
  164. :err
  165. if %where% lss 1 goto documents
  166. ::  NOTE: We've set errr="%bats%\ErrorHandling.bat" <===<< In All Callers. -ed
  167. if not exist %errr% echo ****
  168. if not exist %errr% echo %errr%
  169. if not exist %errr% goto next
  170. ::
  171. set /a exit2=0
  172.  
  173. set txt="Wow, what's this, it worked?"
  174. set sender="copy_control.bat"
  175. call %errr% :next %txt%, sender
  176. ::
  177. title %mstr%
  178. :: rote mods
  179. if %exit2% equ 5 set /a sgnl=4
  180. :: i.e. goto start
  181. if %exit2% gtr 5 set /a sgnl=3
  182. :: i.e. goto exit2
  183. goto return
  184.  
  185.  
  186. :: rote mods
  187. :reco2
  188. set /a where=7
  189. set /a round=(%round%+1)
  190. if %round% equ 1 goto err
  191. set /a sgnl=5
  192.  
  193.  
  194. :return
  195.  
  196.  
  197. :: 100% -JpE-
  198.  
  199.  
  200.  
  201.  
  202.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement