build_pkg.bat 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641
  1. @echo off
  2. @echo Salt Windows Build Package Script
  3. @echo =====================================================================
  4. @echo.
  5. :: Get Passed Parameters
  6. @echo Get Passed Parameters...
  7. @echo ---------------------------------------------------------------------
  8. Set "Version="
  9. Set "Python="
  10. :: First Parameter
  11. if not "%~1"=="" (
  12. echo.%1 | FIND /I "=" > nul && (
  13. :: Named Parameter
  14. set "%~1"
  15. ) || (
  16. :: Positional Parameter
  17. set "Version=%~1"
  18. )
  19. )
  20. :: Second Parameter
  21. if not "%~2"=="" (
  22. echo.%2 | FIND /I "=" > nul && (
  23. :: Named Parameter
  24. set "%~2"
  25. ) || (
  26. :: Positional Parameter
  27. set "Python=%~2"
  28. )
  29. )
  30. :: If Version not defined, Get the version from Git
  31. if "%Version%"=="" (
  32. for /f "delims=" %%a in ('git describe') do @set "Version=%%a"
  33. )
  34. :: If Python not defined, Assume Python 3
  35. if "%Python%"=="" (
  36. set Python=3
  37. )
  38. :: Verify valid Python value (3)
  39. :: We may need to add Python 4 in the future (delims=34)
  40. set "x="
  41. for /f "delims=3" %%i in ("%Python%") do set x=%%i
  42. if Defined x (
  43. echo Invalid Python Version specified. Must be 3. Passed %Python%
  44. goto eof
  45. )
  46. @echo.
  47. :: Define Variables
  48. @echo Defining Variables...
  49. @echo ----------------------------------------------------------------------
  50. if %Python%==3 (
  51. Set "PyDir=C:\Python37"
  52. Set "PyVerMajor=3"
  53. Set "PyVerMinor=7"
  54. ) else (
  55. :: Placeholder for future version
  56. :: Set "PyDir=C:\Python4"
  57. :: Set "PyVerMajor=0"
  58. :: Set "PyVerMinor=0"
  59. )
  60. :: Verify the Python Installation
  61. If not Exist "%PyDir%\python.exe" (
  62. @echo Expected version of Python not found: Python %PyVerMajor%.%PyVerMinor%"
  63. exit /b 1
  64. )
  65. Set "CurDir=%~dp0"
  66. Set "BldDir=%CurDir%buildenv"
  67. Set "BinDir=%CurDir%buildenv\bin"
  68. Set "CnfDir=%CurDir%buildenv\conf"
  69. Set "InsDir=%CurDir%installer"
  70. Set "PreDir=%CurDir%prereqs"
  71. for /f "delims=" %%a in ('git rev-parse --show-toplevel') do @set "SrcDir=%%a"
  72. :: Find the NSIS Installer
  73. If Exist "C:\Program Files\NSIS\" (
  74. Set "NSIS=C:\Program Files\NSIS\"
  75. ) Else (
  76. Set "NSIS=C:\Program Files (x86)\NSIS\"
  77. )
  78. If not Exist "%NSIS%NSIS.exe" (
  79. @echo "NSIS not found in %NSIS%"
  80. exit /b 1
  81. )
  82. :: Add NSIS to the Path
  83. Set "PATH=%NSIS%;%PATH%"
  84. @echo.
  85. :: Check for existing bin directory and remove
  86. If Exist "%BinDir%\" (
  87. @echo Removing %BinDir%
  88. @echo ----------------------------------------------------------------------
  89. rd /S /Q "%BinDir%"
  90. )
  91. :: Copy the contents of the Python Dir to bin
  92. @echo Copying "%PyDir%" to bin...
  93. @echo ----------------------------------------------------------------------
  94. @echo xcopy /E /Q "%PyDir%" "%BinDir%\"
  95. xcopy /E /Q "%PyDir%" "%BinDir%\"
  96. @echo.
  97. :: Copy the default master and minion configs to buildenv\conf
  98. @echo Copying configs to buildenv\conf...
  99. @echo ----------------------------------------------------------------------
  100. @echo xcopy /E /Q "%SrcDir%\conf\master" "%CnfDir%\"
  101. xcopy /Q /Y "%SrcDir%\conf\master" "%CnfDir%\"
  102. @echo xcopy /E /Q "%SrcDir%\conf\minion" "%CnfDir%\"
  103. xcopy /Q /Y "%SrcDir%\conf\minion" "%CnfDir%\"
  104. @echo.
  105. @echo Copying SSM to buildenv
  106. @echo ----------------------------------------------------------------------
  107. :: Set the location of the ssm to download
  108. Set Url64="https://repo.saltstack.com/windows/dependencies/64/ssm-2.24-103-gdee49fc.exe"
  109. Set Url32="https://repo.saltstack.com/windows/dependencies/32/ssm-2.24-103-gdee49fc.exe"
  110. :: Check for 64 bit by finding the Program Files (x86) directory
  111. If Defined ProgramFiles(x86) (
  112. powershell -ExecutionPolicy RemoteSigned -File download_url_file.ps1 -url "%Url64%" -file "%BinDir%\ssm.exe"
  113. ) Else (
  114. powershell -ExecutionPolicy RemoteSigned -File download_url_file.ps1 -url "%Url32%" -file "%BinDir%\ssm.exe"
  115. )
  116. @echo.
  117. :: Make sure the "prereq" directory exists and is empty
  118. If Exist "%PreDir%" rd /s /q "%PreDir%"
  119. mkdir "%PreDir%"
  120. :: UCRT for 32bit is required for both x86 and x64 builds
  121. @echo.
  122. @echo Copying Universal C Runtimes X86 to Prerequisites
  123. @echo ----------------------------------------------------------------------
  124. set Url=http://repo.saltstack.com/windows/dependencies/32/ucrt_x86.zip
  125. set Name=ucrt_x86.zip
  126. @echo - Downloading %Name%
  127. powershell -ExecutionPolicy RemoteSigned -File download_url_file.ps1 -url %Url% -file "%PreDir%\%Name%"
  128. :: 32 bit binaries only needed for x86 installer
  129. :: ProgramFiles(x86) is defined on AMD64 systems
  130. :: If it's defined, skip the x86 binaries
  131. If Defined ProgramFiles(x86) goto vcredist_2013_x64
  132. :vcredist_2013_x86
  133. @echo.
  134. @echo Copying VCRedist 2013 X86 to Prerequisites
  135. @echo ----------------------------------------------------------------------
  136. set Url=http://repo.saltstack.com/windows/dependencies/32/vcredist_x86_2013.exe
  137. set Name=vcredist_x86_2013.exe
  138. @echo - Downloading %Name%
  139. powershell -ExecutionPolicy RemoteSigned -File download_url_file.ps1 -url %Url% -file "%PreDir%\%Name%"
  140. goto prereq_end
  141. :: These are only needed on 64bit installer
  142. :vcredist_2013_x64
  143. @echo.
  144. @echo Copying VCRedist 2013 X64 to Prerequisites
  145. @echo ----------------------------------------------------------------------
  146. set Url=http://repo.saltstack.com/windows/dependencies/64/vcredist_x64_2013.exe
  147. set Name=vcredist_x64_2013.exe
  148. @echo - Downloading %Name%
  149. powershell -ExecutionPolicy RemoteSigned -File download_url_file.ps1 -url %Url% -file "%PreDir%\%Name%"
  150. @echo.
  151. @echo Copying Universal C Runtimes X64 to Prerequisites
  152. @echo ----------------------------------------------------------------------
  153. set Url=http://repo.saltstack.com/windows/dependencies/64/ucrt_x64.zip
  154. set Name=ucrt_x64.zip
  155. @echo - Downloading %Name%
  156. powershell -ExecutionPolicy RemoteSigned -File download_url_file.ps1 -url %Url% -file "%PreDir%\%Name%"
  157. :prereq_end
  158. :: Remove the fixed path in .exe files
  159. @echo Removing fixed path from .exe files
  160. @echo ----------------------------------------------------------------------
  161. "%PyDir%\python" "%CurDir%\portable.py" -f "%BinDir%\Scripts\easy_install.exe"
  162. "%PyDir%\python" "%CurDir%\portable.py" -f "%BinDir%\Scripts\easy_install-%PyVerMajor%.%PyVerMinor%.exe"
  163. "%PyDir%\python" "%CurDir%\portable.py" -f "%BinDir%\Scripts\pip.exe"
  164. "%PyDir%\python" "%CurDir%\portable.py" -f "%BinDir%\Scripts\pip%PyVerMajor%.%PyVerMinor%.exe"
  165. "%PyDir%\python" "%CurDir%\portable.py" -f "%BinDir%\Scripts\pip%PyVerMajor%.exe"
  166. "%PyDir%\python" "%CurDir%\portable.py" -f "%BinDir%\Scripts\wheel.exe"
  167. @echo.
  168. @echo Cleaning up unused files and directories...
  169. @echo ----------------------------------------------------------------------
  170. :: Remove all Compiled Python files (.pyc)
  171. del /S /Q "%BinDir%\*.pyc" 1>nul
  172. :: Remove all Compiled HTML Help (.chm)
  173. del /S /Q "%BinDir%\*.chm" 1>nul
  174. :: Remove all empty text files (they are placeholders for git)
  175. del /S /Q "%BinDir%\..\empty.*" 1>nul
  176. :: Delete Unused Docs and Modules
  177. If Exist "%BinDir%\Doc" rd /S /Q "%BinDir%\Doc"
  178. If Exist "%BinDir%\share" rd /S /Q "%BinDir%\share"
  179. If Exist "%BinDir%\tcl" rd /S /Q "%BinDir%\tcl"
  180. If Exist "%BinDir%\Lib\idlelib" rd /S /Q "%BinDir%\Lib\idlelib"
  181. If Exist "%BinDir%\Lib\lib-tk" rd /S /Q "%BinDir%\Lib\lib-tk"
  182. If Exist "%BinDir%\Lib\test" rd /S /Q "%BinDir%\Lib\test"
  183. If Exist "%BinDir%\Lib\unit-test" rd /S /Q "%BinDir%\Lib\unit-test"
  184. :: Delete Unused .dll files
  185. If Exist "%BinDir%\DLLs\tcl85.dll" del /Q "%BinDir%\DLLs\tcl85.dll" 1>nul
  186. If Exist "%BinDir%\DLLs\tclpip85.dll" del /Q "%BinDir%\DLLs\tclpip85.dll" 1>nul
  187. If Exist "%BinDir%\DLLs\tk85.dll" del /Q "%BinDir%\DLLs\tk85.dll" 1>nul
  188. :: Delete Unused .lib files
  189. If Exist "%BinDir%\libs\_tkinter.lib" del /Q "%BinDir%\libs\_tkinter.lib" 1>nul
  190. :: Delete .txt files
  191. If Exist "%BinDir%\NEWS.txt" del /Q "%BinDir%\NEWS.txt" 1>nul
  192. If Exist "%BinDir%\README.txt" del /Q "%BinDir%\README.txt" 1>nul
  193. :: Delete Non-Windows Modules
  194. If Exist "%BinDir%\Lib\site-packages\salt\modules\acme.py"^
  195. del /Q "%BinDir%\Lib\site-packages\salt\modules\acme.*" 1>nul
  196. If Exist "%BinDir%\Lib\site-packages\salt\modules\alternatives.py"^
  197. del /Q "%BinDir%\Lib\site-packages\salt\modules\alternatives.*" 1>nul
  198. If Exist "%BinDir%\Lib\site-packages\salt\modules\apf.py"^
  199. del /Q "%BinDir%\Lib\site-packages\salt\modules\apf.*" 1>nul
  200. If Exist "%BinDir%\Lib\site-packages\salt\modules\aptpkg.py"^
  201. del /Q "%BinDir%\Lib\site-packages\salt\modules\aptpkg.*" 1>nul
  202. If Exist "%BinDir%\Lib\site-packages\salt\modules\at.py"^
  203. del /Q "%BinDir%\Lib\site-packages\salt\modules\at.*" 1>nul
  204. If Exist "%BinDir%\Lib\site-packages\salt\modules\bcache.py"^
  205. del /Q "%BinDir%\Lib\site-packages\salt\modules\bcache.*" 1>nul
  206. If Exist "%BinDir%\Lib\site-packages\salt\modules\blockdev.py"^
  207. del /Q "%BinDir%\Lib\site-packages\salt\modules\blockdev.*" 1>nul
  208. If Exist "%BinDir%\Lib\site-packages\salt\modules\bluez.py"^
  209. del /Q "%BinDir%\Lib\site-packages\salt\modules\bluez.*" 1>nul
  210. If Exist "%BinDir%\Lib\site-packages\salt\modules\bridge.py"^
  211. del /Q "%BinDir%\Lib\site-packages\salt\modules\bridge.*" 1>nul
  212. If Exist "%BinDir%\Lib\site-packages\salt\modules\bsd_shadow.py"^
  213. del /Q "%BinDir%\Lib\site-packages\salt\modules\bsd_shadow.*" 1>nul
  214. If Exist "%BinDir%\Lib\site-packages\salt\modules\btrfs.py"^
  215. del /Q "%BinDir%\Lib\site-packages\salt\modules\btrfs.*" 1>nul
  216. If Exist "%BinDir%\Lib\site-packages\salt\modules\ceph.py"^
  217. del /Q "%BinDir%\Lib\site-packages\salt\modules\ceph.*" 1>nul
  218. If Exist "%BinDir%\Lib\site-packages\salt\modules\container_resource.py"^
  219. del /Q "%BinDir%\Lib\site-packages\salt\modules\container_resource.*" 1>nul
  220. If Exist "%BinDir%\Lib\site-packages\salt\modules\cron.py"^
  221. del /Q "%BinDir%\Lib\site-packages\salt\modules\cron.*" 1>nul
  222. If Exist "%BinDir%\Lib\site-packages\salt\modules\csf.py"^
  223. del /Q "%BinDir%\Lib\site-packages\salt\modules\csf.*" 1>nul
  224. If Exist "%BinDir%\Lib\site-packages\salt\modules\daemontools.py"^
  225. del /Q "%BinDir%\Lib\site-packages\salt\modules\daemontools.*" 1>nul
  226. If Exist "%BinDir%\Lib\site-packages\salt\modules\deb*"^
  227. del /Q "%BinDir%\Lib\site-packages\salt\modules\deb*" 1>nul
  228. If Exist "%BinDir%\Lib\site-packages\salt\modules\devmap.py"^
  229. del /Q "%BinDir%\Lib\site-packages\salt\modules\devmap.*" 1>nul
  230. If Exist "%BinDir%\Lib\site-packages\salt\modules\dpkg.py"^
  231. del /Q "%BinDir%\Lib\site-packages\salt\modules\dpkg.*" 1>nul
  232. If Exist "%BinDir%\Lib\site-packages\salt\modules\ebuild.py"^
  233. del /Q "%BinDir%\Lib\site-packages\salt\modules\ebuild.*" 1>nul
  234. If Exist "%BinDir%\Lib\site-packages\salt\modules\eix.py"^
  235. del /Q "%BinDir%\Lib\site-packages\salt\modules\eix.*" 1>nul
  236. If Exist "%BinDir%\Lib\site-packages\salt\modules\eselect.py"^
  237. del /Q "%BinDir%\Lib\site-packages\salt\modules\eselect.*" 1>nul
  238. If Exist "%BinDir%\Lib\site-packages\salt\modules\ethtool.py"^
  239. del /Q "%BinDir%\Lib\site-packages\salt\modules\ethtool.*" 1>nul
  240. If Exist "%BinDir%\Lib\site-packages\salt\modules\extfs.py"^
  241. del /Q "%BinDir%\Lib\site-packages\salt\modules\extfs.*" 1>nul
  242. If Exist "%BinDir%\Lib\site-packages\salt\modules\firewalld.py"^
  243. del /Q "%BinDir%\Lib\site-packages\salt\modules\firewalld.*" 1>nul
  244. If Exist "%BinDir%\Lib\site-packages\salt\modules\freebsd*"^
  245. del /Q "%BinDir%\Lib\site-packages\salt\modules\freebsd*" 1>nul
  246. If Exist "%BinDir%\Lib\site-packages\salt\modules\genesis.py"^
  247. del /Q "%BinDir%\Lib\site-packages\salt\modules\genesis.*" 1>nul
  248. If Exist "%BinDir%\Lib\site-packages\salt\modules\gentoo*"^
  249. del /Q "%BinDir%\Lib\site-packages\salt\modules\gentoo*" 1>nul
  250. If Exist "%BinDir%\Lib\site-packages\salt\modules\glusterfs.py"^
  251. del /Q "%BinDir%\Lib\site-packages\salt\modules\glusterfs.*" 1>nul
  252. If Exist "%BinDir%\Lib\site-packages\salt\modules\gnomedesktop.py"^
  253. del /Q "%BinDir%\Lib\site-packages\salt\modules\gnomedesktop.*" 1>nul
  254. If Exist "%BinDir%\Lib\site-packages\salt\modules\groupadd.py"^
  255. del /Q "%BinDir%\Lib\site-packages\salt\modules\groupadd.*" 1>nul
  256. If Exist "%BinDir%\Lib\site-packages\salt\modules\grub_legacy.py"^
  257. del /Q "%BinDir%\Lib\site-packages\salt\modules\grub_legacy.*" 1>nul
  258. If Exist "%BinDir%\Lib\site-packages\salt\modules\guestfs.py"^
  259. del /Q "%BinDir%\Lib\site-packages\salt\modules\guestfs.*" 1>nul
  260. If Exist "%BinDir%\Lib\site-packages\salt\modules\htpasswd.py"^
  261. del /Q "%BinDir%\Lib\site-packages\salt\modules\htpasswd.*" 1>nul
  262. If Exist "%BinDir%\Lib\site-packages\salt\modules\ilo.py"^
  263. del /Q "%BinDir%\Lib\site-packages\salt\modules\ilo.*" 1>nul
  264. If Exist "%BinDir%\Lib\site-packages\salt\modules\img.py"^
  265. del /Q "%BinDir%\Lib\site-packages\salt\modules\img.*" 1>nul
  266. If Exist "%BinDir%\Lib\site-packages\salt\modules\incron.py"^
  267. del /Q "%BinDir%\Lib\site-packages\salt\modules\incron.*" 1>nul
  268. If Exist "%BinDir%\Lib\site-packages\salt\modules\inspector.py"^
  269. del /Q "%BinDir%\Lib\site-packages\salt\modules\inspector.*" 1>nul
  270. If Exist "%BinDir%\Lib\site-packages\salt\modules\ipset.py"^
  271. del /Q "%BinDir%\Lib\site-packages\salt\modules\ipset.*" 1>nul
  272. If Exist "%BinDir%\Lib\site-packages\salt\modules\iptables.py"^
  273. del /Q "%BinDir%\Lib\site-packages\salt\modules\iptables.*" 1>nul
  274. If Exist "%BinDir%\Lib\site-packages\salt\modules\iwtools.py"^
  275. del /Q "%BinDir%\Lib\site-packages\salt\modules\iwtools.*" 1>nul
  276. If Exist "%BinDir%\Lib\site-packages\salt\modules\k8s.py"^
  277. del /Q "%BinDir%\Lib\site-packages\salt\modules\k8s.*" 1>nul
  278. If Exist "%BinDir%\Lib\site-packages\salt\modules\kapacitor.py"^
  279. del /Q "%BinDir%\Lib\site-packages\salt\modules\kapacitor.*" 1>nul
  280. If Exist "%BinDir%\Lib\site-packages\salt\modules\keyboard.py"^
  281. del /Q "%BinDir%\Lib\site-packages\salt\modules\keyboard.*" 1>nul
  282. If Exist "%BinDir%\Lib\site-packages\salt\modules\keystone.py"^
  283. del /Q "%BinDir%\Lib\site-packages\salt\modules\keystone.*" 1>nul
  284. If Exist "%BinDir%\Lib\site-packages\salt\modules\kmod.py"^
  285. del /Q "%BinDir%\Lib\site-packages\salt\modules\kmod.*" 1>nul
  286. If Exist "%BinDir%\Lib\site-packages\salt\modules\layman.py"^
  287. del /Q "%BinDir%\Lib\site-packages\salt\modules\layman.*" 1>nul
  288. If Exist "%BinDir%\Lib\site-packages\salt\modules\linux*"^
  289. del /Q "%BinDir%\Lib\site-packages\salt\modules\linux*" 1>nul
  290. If Exist "%BinDir%\Lib\site-packages\salt\modules\localemod.py"^
  291. del /Q "%BinDir%\Lib\site-packages\salt\modules\localemod.*" 1>nul
  292. If Exist "%BinDir%\Lib\site-packages\salt\modules\locate.py"^
  293. del /Q "%BinDir%\Lib\site-packages\salt\modules\locate.*" 1>nul
  294. If Exist "%BinDir%\Lib\site-packages\salt\modules\logadm.py"^
  295. del /Q "%BinDir%\Lib\site-packages\salt\modules\logadm.*" 1>nul
  296. If Exist "%BinDir%\Lib\site-packages\salt\modules\logrotate.py"^
  297. del /Q "%BinDir%\Lib\site-packages\salt\modules\logrotate.*" 1>nul
  298. If Exist "%BinDir%\Lib\site-packages\salt\modules\lvs.py"^
  299. del /Q "%BinDir%\Lib\site-packages\salt\modules\lvs.*" 1>nul
  300. If Exist "%BinDir%\Lib\site-packages\salt\modules\lxc.py"^
  301. del /Q "%BinDir%\Lib\site-packages\salt\modules\lxc.*" 1>nul
  302. If Exist "%BinDir%\Lib\site-packages\salt\modules\mac*"^
  303. del /Q "%BinDir%\Lib\site-packages\salt\modules\mac*" 1>nul
  304. If Exist "%BinDir%\Lib\site-packages\salt\modules\makeconf.py"^
  305. del /Q "%BinDir%\Lib\site-packages\salt\modules\makeconf.*" 1>nul
  306. If Exist "%BinDir%\Lib\site-packages\salt\modules\mdadm.py"^
  307. del /Q "%BinDir%\Lib\site-packages\salt\modules\mdadm.*" 1>nul
  308. If Exist "%BinDir%\Lib\site-packages\salt\modules\mdata.py"^
  309. del /Q "%BinDir%\Lib\site-packages\salt\modules\mdata.*" 1>nul
  310. If Exist "%BinDir%\Lib\site-packages\salt\modules\monit.py"^
  311. del /Q "%BinDir%\Lib\site-packages\salt\modules\monit.*" 1>nul
  312. If Exist "%BinDir%\Lib\site-packages\salt\modules\moosefs.py"^
  313. del /Q "%BinDir%\Lib\site-packages\salt\modules\moosefs.*" 1>nul
  314. If Exist "%BinDir%\Lib\site-packages\salt\modules\mount.py"^
  315. del /Q "%BinDir%\Lib\site-packages\salt\modules\mount.*" 1>nul
  316. If Exist "%BinDir%\Lib\site-packages\salt\modules\napalm*"^
  317. del /Q "%BinDir%\Lib\site-packages\salt\modules\napalm*" 1>nul
  318. If Exist "%BinDir%\Lib\site-packages\salt\modules\netbsd*"^
  319. del /Q "%BinDir%\Lib\site-packages\salt\modules\netbsd*" 1>nul
  320. If Exist "%BinDir%\Lib\site-packages\salt\modules\netscaler.py"^
  321. del /Q "%BinDir%\Lib\site-packages\salt\modules\netscaler.*" 1>nul
  322. If Exist "%BinDir%\Lib\site-packages\salt\modules\neutron.py"^
  323. del /Q "%BinDir%\Lib\site-packages\salt\modules\neutron.*" 1>nul
  324. If Exist "%BinDir%\Lib\site-packages\salt\modules\nfs3.py"^
  325. del /Q "%BinDir%\Lib\site-packages\salt\modules\nfs3.*" 1>nul
  326. If Exist "%BinDir%\Lib\site-packages\salt\modules\nftables.py"^
  327. del /Q "%BinDir%\Lib\site-packages\salt\modules\nftables.*" 1>nul
  328. If Exist "%BinDir%\Lib\site-packages\salt\modules\nova.py"^
  329. del /Q "%BinDir%\Lib\site-packages\salt\modules\nova.*" 1>nul
  330. If Exist "%BinDir%\Lib\site-packages\salt\modules\nspawn.py"^
  331. del /Q "%BinDir%\Lib\site-packages\salt\modules\nspawn.*" 1>nul
  332. If Exist "%BinDir%\Lib\site-packages\salt\modules\openbsd*"^
  333. del /Q "%BinDir%\Lib\site-packages\salt\modules\openbsd*" 1>nul
  334. If Exist "%BinDir%\Lib\site-packages\salt\modules\openstack_mng.py"^
  335. del /Q "%BinDir%\Lib\site-packages\salt\modules\openstack_mng.*" 1>nul
  336. If Exist "%BinDir%\Lib\site-packages\salt\modules\openvswitch.py"^
  337. del /Q "%BinDir%\Lib\site-packages\salt\modules\openvswitch.*" 1>nul
  338. If Exist "%BinDir%\Lib\site-packages\salt\modules\opkg.py"^
  339. del /Q "%BinDir%\Lib\site-packages\salt\modules\opkg.*" 1>nul
  340. If Exist "%BinDir%\Lib\site-packages\salt\modules\pacman.py"^
  341. del /Q "%BinDir%\Lib\site-packages\salt\modules\pacman.*" 1>nul
  342. If Exist "%BinDir%\Lib\site-packages\salt\modules\parallels.py"^
  343. del /Q "%BinDir%\Lib\site-packages\salt\modules\parallels.*" 1>nul
  344. If Exist "%BinDir%\Lib\site-packages\salt\modules\parted.py"^
  345. del /Q "%BinDir%\Lib\site-packages\salt\modules\parted.*" 1>nul
  346. If Exist "%BinDir%\Lib\site-packages\salt\modules\pcs.py"^
  347. del /Q "%BinDir%\Lib\site-packages\salt\modules\pcs.*" 1>nul
  348. If Exist "%BinDir%\Lib\site-packages\salt\modules\pkgin.py"^
  349. del /Q "%BinDir%\Lib\site-packages\salt\modules\pkgin.*" 1>nul
  350. If Exist "%BinDir%\Lib\site-packages\salt\modules\pkgng.py"^
  351. del /Q "%BinDir%\Lib\site-packages\salt\modules\pkgng.*" 1>nul
  352. If Exist "%BinDir%\Lib\site-packages\salt\modules\pkgutil.py"^
  353. del /Q "%BinDir%\Lib\site-packages\salt\modules\pkgutil.*" 1>nul
  354. If Exist "%BinDir%\Lib\site-packages\salt\modules\portage_config.py"^
  355. del /Q "%BinDir%\Lib\site-packages\salt\modules\portage_config.*" 1>nul
  356. If Exist "%BinDir%\Lib\site-packages\salt\modules\postfix.py"^
  357. del /Q "%BinDir%\Lib\site-packages\salt\modules\postfix.*" 1>nul
  358. If Exist "%BinDir%\Lib\site-packages\salt\modules\poudriere.py"^
  359. del /Q "%BinDir%\Lib\site-packages\salt\modules\poudriere.*" 1>nul
  360. If Exist "%BinDir%\Lib\site-packages\salt\modules\powerpath.py"^
  361. del /Q "%BinDir%\Lib\site-packages\salt\modules\powerpath.*" 1>nul
  362. If Exist "%BinDir%\Lib\site-packages\salt\modules\pw_*"^
  363. del /Q "%BinDir%\Lib\site-packages\salt\modules\pw_*" 1>nul
  364. If Exist "%BinDir%\Lib\site-packages\salt\modules\qemu_ndb.py"^
  365. del /Q "%BinDir%\Lib\site-packages\salt\modules\qemu_ndb.*" 1>nul
  366. If Exist "%BinDir%\Lib\site-packages\salt\modules\quota.py"^
  367. del /Q "%BinDir%\Lib\site-packages\salt\modules\quota.*" 1>nul
  368. If Exist "%BinDir%\Lib\site-packages\salt\modules\redismod.py"^
  369. del /Q "%BinDir%\Lib\site-packages\salt\modules\redismod.*" 1>nul
  370. If Exist "%BinDir%\Lib\site-packages\salt\modules\restartcheck.py"^
  371. del /Q "%BinDir%\Lib\site-packages\salt\modules\restartcheck.*" 1>nul
  372. If Exist "%BinDir%\Lib\site-packages\salt\modules\rh_*"^
  373. del /Q "%BinDir%\Lib\site-packages\salt\modules\rh_*" 1>nul
  374. If Exist "%BinDir%\Lib\site-packages\salt\modules\riak.py"^
  375. del /Q "%BinDir%\Lib\site-packages\salt\modules\riak.*" 1>nul
  376. If Exist "%BinDir%\Lib\site-packages\salt\modules\rpm*"^
  377. del /Q "%BinDir%\Lib\site-packages\salt\modules\rpm*" 1>nul
  378. If Exist "%BinDir%\Lib\site-packages\salt\modules\runit.py"^
  379. del /Q "%BinDir%\Lib\site-packages\salt\modules\runit.*" 1>nul
  380. If Exist "%BinDir%\Lib\site-packages\salt\modules\s6.py"^
  381. del /Q "%BinDir%\Lib\site-packages\salt\modules\s6.*" 1>nul
  382. If Exist "%BinDir%\Lib\site-packages\salt\modules\scsi.py"^
  383. del /Q "%BinDir%\Lib\site-packages\salt\modules\scsi.*" 1>nul
  384. If Exist "%BinDir%\Lib\site-packages\salt\modules\seed.py"^
  385. del /Q "%BinDir%\Lib\site-packages\salt\modules\seed.*" 1>nul
  386. If Exist "%BinDir%\Lib\site-packages\salt\modules\sensors.py"^
  387. del /Q "%BinDir%\Lib\site-packages\salt\modules\sensors.*" 1>nul
  388. If Exist "%BinDir%\Lib\site-packages\salt\modules\service.py"^
  389. del /Q "%BinDir%\Lib\site-packages\salt\modules\service.*" 1>nul
  390. If Exist "%BinDir%\Lib\site-packages\salt\modules\shadow.py"^
  391. del /Q "%BinDir%\Lib\site-packages\salt\modules\shadow.*" 1>nul
  392. If Exist "%BinDir%\Lib\site-packages\salt\modules\smartos*"^
  393. del /Q "%BinDir%\Lib\site-packages\salt\modules\smartos*" 1>nul
  394. If Exist "%BinDir%\Lib\site-packages\salt\modules\smf.py"^
  395. del /Q "%BinDir%\Lib\site-packages\salt\modules\smf.*" 1>nul
  396. If Exist "%BinDir%\Lib\site-packages\salt\modules\snapper.py"^
  397. del /Q "%BinDir%\Lib\site-packages\salt\modules\snapper.*" 1>nul
  398. If Exist "%BinDir%\Lib\site-packages\salt\modules\solaris*"^
  399. del /Q "%BinDir%\Lib\site-packages\salt\modules\solaris*" 1>nul
  400. If Exist "%BinDir%\Lib\site-packages\salt\modules\solr.py"^
  401. del /Q "%BinDir%\Lib\site-packages\salt\modules\solr.*" 1>nul
  402. If Exist "%BinDir%\Lib\site-packages\salt\modules\ssh_*"^
  403. del /Q "%BinDir%\Lib\site-packages\salt\modules\ssh_*" 1>nul
  404. If Exist "%BinDir%\Lib\site-packages\salt\modules\supervisord.py"^
  405. del /Q "%BinDir%\Lib\site-packages\salt\modules\supervisord.*" 1>nul
  406. If Exist "%BinDir%\Lib\site-packages\salt\modules\sysbench.py"^
  407. del /Q "%BinDir%\Lib\site-packages\salt\modules\sysbench.*" 1>nul
  408. If Exist "%BinDir%\Lib\site-packages\salt\modules\sysfs.py"^
  409. del /Q "%BinDir%\Lib\site-packages\salt\modules\sysfs.*" 1>nul
  410. If Exist "%BinDir%\Lib\site-packages\salt\modules\sysrc.py"^
  411. del /Q "%BinDir%\Lib\site-packages\salt\modules\sysrc.*" 1>nul
  412. If Exist "%BinDir%\Lib\site-packages\salt\modules\system.py"^
  413. del /Q "%BinDir%\Lib\site-packages\salt\modules\system.*" 1>nul
  414. If Exist "%BinDir%\Lib\site-packages\salt\modules\test_virtual.py"^
  415. del /Q "%BinDir%\Lib\site-packages\salt\modules\test_virtual.*" 1>nul
  416. If Exist "%BinDir%\Lib\site-packages\salt\modules\timezone.py"^
  417. del /Q "%BinDir%\Lib\site-packages\salt\modules\timezone.*" 1>nul
  418. If Exist "%BinDir%\Lib\site-packages\salt\modules\trafficserver.py"^
  419. del /Q "%BinDir%\Lib\site-packages\salt\modules\trafficserver.*" 1>nul
  420. If Exist "%BinDir%\Lib\site-packages\salt\modules\tuned.py"^
  421. del /Q "%BinDir%\Lib\site-packages\salt\modules\tuned.*" 1>nul
  422. If Exist "%BinDir%\Lib\site-packages\salt\modules\udev.py"^
  423. del /Q "%BinDir%\Lib\site-packages\salt\modules\udev.*" 1>nul
  424. If Exist "%BinDir%\Lib\site-packages\salt\modules\upstart.py"^
  425. del /Q "%BinDir%\Lib\site-packages\salt\modules\upstart.*" 1>nul
  426. If Exist "%BinDir%\Lib\site-packages\salt\modules\useradd.py"^
  427. del /Q "%BinDir%\Lib\site-packages\salt\modules\useradd.*" 1>nul
  428. If Exist "%BinDir%\Lib\site-packages\salt\modules\uswgi.py"^
  429. del /Q "%BinDir%\Lib\site-packages\salt\modules\uswgi.*" 1>nul
  430. If Exist "%BinDir%\Lib\site-packages\salt\modules\varnish.py"^
  431. del /Q "%BinDir%\Lib\site-packages\salt\modules\varnish.*" 1>nul
  432. If Exist "%BinDir%\Lib\site-packages\salt\modules\vbox_guest.py"^
  433. del /Q "%BinDir%\Lib\site-packages\salt\modules\vbox_guest.*" 1>nul
  434. If Exist "%BinDir%\Lib\site-packages\salt\modules\vboxmanage.py"^
  435. del /Q "%BinDir%\Lib\site-packages\salt\modules\vboxmanage.*" 1>nul
  436. If Exist "%BinDir%\Lib\site-packages\salt\modules\virt.py"^
  437. del /Q "%BinDir%\Lib\site-packages\salt\modules\virt.*" 1>nul
  438. If Exist "%BinDir%\Lib\site-packages\salt\modules\xapi.py"^
  439. del /Q "%BinDir%\Lib\site-packages\salt\modules\xapi.*" 1>nul
  440. If Exist "%BinDir%\Lib\site-packages\salt\modules\xbpspkg.py"^
  441. del /Q "%BinDir%\Lib\site-packages\salt\modules\xbpspkg.*" 1>nul
  442. If Exist "%BinDir%\Lib\site-packages\salt\modules\xfs.py"^
  443. del /Q "%BinDir%\Lib\site-packages\salt\modules\xfs.*" 1>nul
  444. If Exist "%BinDir%\Lib\site-packages\salt\modules\yumpkg.py"^
  445. del /Q "%BinDir%\Lib\site-packages\salt\modules\yum.*" 1>nul
  446. If Exist "%BinDir%\Lib\site-packages\salt\modules\zfs.py"^
  447. del /Q "%BinDir%\Lib\site-packages\salt\modules\zfs.*" 1>nul
  448. If Exist "%BinDir%\Lib\site-packages\salt\modules\znc.py"^
  449. del /Q "%BinDir%\Lib\site-packages\salt\modules\znc.*" 1>nul
  450. If Exist "%BinDir%\Lib\site-packages\salt\modules\zpool.py"^
  451. del /Q "%BinDir%\Lib\site-packages\salt\modules\zpool.*" 1>nul
  452. If Exist "%BinDir%\Lib\site-packages\salt\modules\zypper.py"^
  453. del /Q "%BinDir%\Lib\site-packages\salt\modules\zypper.*" 1>nul
  454. :: Delete Non-Windows States
  455. If Exist "%BinDir%\Lib\site-packages\salt\states\acme.py"^
  456. del /Q "%BinDir%\Lib\site-packages\salt\states\acme.*" 1>nul
  457. If Exist "%BinDir%\Lib\site-packages\salt\states\alternatives.py"^
  458. del /Q "%BinDir%\Lib\site-packages\salt\states\alternatives.*" 1>nul
  459. If Exist "%BinDir%\Lib\site-packages\salt\states\aptpkg.py"^
  460. del /Q "%BinDir%\Lib\site-packages\salt\states\aptpkg.*" 1>nul
  461. If Exist "%BinDir%\Lib\site-packages\salt\states\at.py"^
  462. del /Q "%BinDir%\Lib\site-packages\salt\states\at.*" 1>nul
  463. If Exist "%BinDir%\Lib\site-packages\salt\states\blockdev.py"^
  464. del /Q "%BinDir%\Lib\site-packages\salt\states\blockdev.*" 1>nul
  465. If Exist "%BinDir%\Lib\site-packages\salt\states\ceph.py"^
  466. del /Q "%BinDir%\Lib\site-packages\salt\states\ceph.*" 1>nul
  467. If Exist "%BinDir%\Lib\site-packages\salt\states\cron.py"^
  468. del /Q "%BinDir%\Lib\site-packages\salt\states\cron.*" 1>nul
  469. If Exist "%BinDir%\Lib\site-packages\salt\states\csf.py"^
  470. del /Q "%BinDir%\Lib\site-packages\salt\states\csf.*" 1>nul
  471. If Exist "%BinDir%\Lib\site-packages\salt\states\debconfmod.py"^
  472. del /Q "%BinDir%\Lib\site-packages\salt\states\debconfmod.*" 1>nul
  473. If Exist "%BinDir%\Lib\site-packages\salt\states\eselect.py"^
  474. del /Q "%BinDir%\Lib\site-packages\salt\states\eselect.*" 1>nul
  475. If Exist "%BinDir%\Lib\site-packages\salt\states\ethtool.py"^
  476. del /Q "%BinDir%\Lib\site-packages\salt\states\ethtool.*" 1>nul
  477. If Exist "%BinDir%\Lib\site-packages\salt\states\firewalld.py"^
  478. del /Q "%BinDir%\Lib\site-packages\salt\states\firewalld.*" 1>nul
  479. If Exist "%BinDir%\Lib\site-packages\salt\states\glusterfs.py"^
  480. del /Q "%BinDir%\Lib\site-packages\salt\states\glusterfs.*" 1>nul
  481. If Exist "%BinDir%\Lib\site-packages\salt\states\gnomedesktop.py"^
  482. del /Q "%BinDir%\Lib\site-packages\salt\states\gnomedesktop.*" 1>nul
  483. If Exist "%BinDir%\Lib\site-packages\salt\states\htpasswd.py"^
  484. del /Q "%BinDir%\Lib\site-packages\salt\states\htpasswd.*" 1>nul
  485. If Exist "%BinDir%\Lib\site-packages\salt\states\incron.py"^
  486. del /Q "%BinDir%\Lib\site-packages\salt\states\incron.*" 1>nul
  487. If Exist "%BinDir%\Lib\site-packages\salt\states\ipset.py"^
  488. del /Q "%BinDir%\Lib\site-packages\salt\states\ipset.*" 1>nul
  489. If Exist "%BinDir%\Lib\site-packages\salt\states\iptables.py"^
  490. del /Q "%BinDir%\Lib\site-packages\salt\states\iptables.*" 1>nul
  491. If Exist "%BinDir%\Lib\site-packages\salt\states\k8s.py"^
  492. del /Q "%BinDir%\Lib\site-packages\salt\states\k8s.*" 1>nul
  493. If Exist "%BinDir%\Lib\site-packages\salt\states\kapacitor.py"^
  494. del /Q "%BinDir%\Lib\site-packages\salt\states\kapacitor.*" 1>nul
  495. If Exist "%BinDir%\Lib\site-packages\salt\states\keyboard.py"^
  496. del /Q "%BinDir%\Lib\site-packages\salt\states\keyboard.*" 1>nul
  497. If Exist "%BinDir%\Lib\site-packages\salt\states\keystone.py"^
  498. del /Q "%BinDir%\Lib\site-packages\salt\states\keystone.*" 1>nul
  499. If Exist "%BinDir%\Lib\site-packages\salt\states\kmod.py"^
  500. del /Q "%BinDir%\Lib\site-packages\salt\states\kmod.*" 1>nul
  501. If Exist "%BinDir%\Lib\site-packages\salt\states\layman.py"^
  502. del /Q "%BinDir%\Lib\site-packages\salt\states\layman.*" 1>nul
  503. If Exist "%BinDir%\Lib\site-packages\salt\states\linux*"^
  504. del /Q "%BinDir%\Lib\site-packages\salt\states\linux*" 1>nul
  505. If Exist "%BinDir%\Lib\site-packages\salt\states\lxc.py"^
  506. del /Q "%BinDir%\Lib\site-packages\salt\states\lxc.*" 1>nul
  507. If Exist "%BinDir%\Lib\site-packages\salt\states\mac_*"^
  508. del /Q "%BinDir%\Lib\site-packages\salt\states\mac_*" 1>nul
  509. If Exist "%BinDir%\Lib\site-packages\salt\states\makeconf.py"^
  510. del /Q "%BinDir%\Lib\site-packages\salt\states\makeconf.*" 1>nul
  511. If Exist "%BinDir%\Lib\site-packages\salt\states\mdadm.py"^
  512. del /Q "%BinDir%\Lib\site-packages\salt\states\mdadm.*" 1>nul
  513. If Exist "%BinDir%\Lib\site-packages\salt\states\monit.py"^
  514. del /Q "%BinDir%\Lib\site-packages\salt\states\monit.*" 1>nul
  515. If Exist "%BinDir%\Lib\site-packages\salt\states\mount.py"^
  516. del /Q "%BinDir%\Lib\site-packages\salt\states\mount.*" 1>nul
  517. If Exist "%BinDir%\Lib\site-packages\salt\states\nftables.py"^
  518. del /Q "%BinDir%\Lib\site-packages\salt\states\nftables.*" 1>nul
  519. If Exist "%BinDir%\Lib\site-packages\salt\states\pcs.py"^
  520. del /Q "%BinDir%\Lib\site-packages\salt\states\pcs.*" 1>nul
  521. If Exist "%BinDir%\Lib\site-packages\salt\states\pkgng.py"^
  522. del /Q "%BinDir%\Lib\site-packages\salt\states\pkgng.*" 1>nul
  523. If Exist "%BinDir%\Lib\site-packages\salt\states\portage_config.py"^
  524. del /Q "%BinDir%\Lib\site-packages\salt\states\portage_config.*" 1>nul
  525. If Exist "%BinDir%\Lib\site-packages\salt\states\powerpath.py"^
  526. del /Q "%BinDir%\Lib\site-packages\salt\states\powerpath.*" 1>nul
  527. If Exist "%BinDir%\Lib\site-packages\salt\states\quota.py"^
  528. del /Q "%BinDir%\Lib\site-packages\salt\states\quota.*" 1>nul
  529. If Exist "%BinDir%\Lib\site-packages\salt\states\redismod.py"^
  530. del /Q "%BinDir%\Lib\site-packages\salt\states\redismod.*" 1>nul
  531. If Exist "%BinDir%\Lib\site-packages\salt\states\smartos.py"^
  532. del /Q "%BinDir%\Lib\site-packages\salt\states\smartos.*" 1>nul
  533. If Exist "%BinDir%\Lib\site-packages\salt\states\snapper.py"^
  534. del /Q "%BinDir%\Lib\site-packages\salt\states\snapper.*" 1>nul
  535. If Exist "%BinDir%\Lib\site-packages\salt\states\ssh_*"^
  536. del /Q "%BinDir%\Lib\site-packages\salt\states\ssh_*" 1>nul
  537. If Exist "%BinDir%\Lib\site-packages\salt\states\supervisord.py"^
  538. del /Q "%BinDir%\Lib\site-packages\salt\states\supervisord.*" 1>nul
  539. If Exist "%BinDir%\Lib\site-packages\salt\states\sysrc.py"^
  540. del /Q "%BinDir%\Lib\site-packages\salt\states\sysrc.*" 1>nul
  541. If Exist "%BinDir%\Lib\site-packages\salt\states\trafficserver.py"^
  542. del /Q "%BinDir%\Lib\site-packages\salt\states\trafficserver.*" 1>nul
  543. If Exist "%BinDir%\Lib\site-packages\salt\states\tuned.py"^
  544. del /Q "%BinDir%\Lib\site-packages\salt\states\tuned.*" 1>nul
  545. If Exist "%BinDir%\Lib\site-packages\salt\states\vbox_guest.py"^
  546. del /Q "%BinDir%\Lib\site-packages\salt\states\vbox_guest.*" 1>nul
  547. If Exist "%BinDir%\Lib\site-packages\salt\states\virt.py"^
  548. del /Q "%BinDir%\Lib\site-packages\salt\states\virt.*" 1>nul
  549. If Exist "%BinDir%\Lib\site-packages\salt\states\zfs.py"^
  550. del /Q "%BinDir%\Lib\site-packages\salt\states\zfs.*" 1>nul
  551. If Exist "%BinDir%\Lib\site-packages\salt\states\zpool.py"^
  552. del /Q "%BinDir%\Lib\site-packages\salt\states\zpool.*" 1>nul
  553. :: Remove Unneeded Components
  554. If Exist "%BinDir%\Lib\site-packages\salt\cloud"^
  555. rd /S /Q "%BinDir%\Lib\site-packages\salt\cloud" 1>nul
  556. If Exist "%BinDir%\Scripts\salt-unity*"^
  557. del /Q "%BinDir%\Scripts\salt-unity*" 1>nul
  558. @echo.
  559. @echo Building the installer...
  560. @echo ----------------------------------------------------------------------
  561. :: Make the Master installer if the nullsoft script exists
  562. If Exist "%InsDir%\Salt-Setup.nsi"^
  563. makensis.exe /DSaltVersion=%Version% /DPythonVersion=%Python% "%InsDir%\Salt-Setup.nsi"
  564. :: Remove files not needed for Salt Minion
  565. :: salt
  566. :: salt has to be removed individually (can't wildcard it)
  567. If Exist "%BinDir%\Scripts\salt"^
  568. del /Q "%BinDir%\Scripts\salt" 1>nul
  569. If Exist "%BinDir%\Scripts\salt.exe"^
  570. del /Q "%BinDir%\Scripts\salt.exe" 1>nul
  571. If Exist "%BldDir%\salt.bat"^
  572. del /Q "%BldDir%\salt.bat" 1>nul
  573. :: salt-key
  574. If Exist "%BinDir%\Scripts\salt-key*"^
  575. del /Q "%BinDir%\Scripts\salt-key*" 1>nul
  576. If Exist "%BldDir%\salt-key.bat"^
  577. del /Q "%BldDir%\salt-key.bat" 1>nul
  578. :: salt-master
  579. If Exist "%BinDir%\Scripts\salt-master*"^
  580. del /Q "%BinDir%\Scripts\salt-master*" 1>nul
  581. If Exist "%BldDir%\salt-master.bat"^
  582. del /Q "%BldDir%\salt-master.bat" 1>nul
  583. :: salt-run
  584. If Exist "%BinDir%\Scripts\salt-run*"^
  585. del /Q "%BinDir%\Scripts\salt-run*" 1>nul
  586. If Exist "%BldDir%\salt-run.bat"^
  587. del /Q "%BldDir%\salt-run.bat" 1>nul
  588. :: Remove the master config file
  589. if Exist "%CnfDir%\master"^
  590. del /Q "%CnfDir%\master" 1>nul
  591. :: Make the Salt Minion Installer
  592. makensis.exe /DSaltVersion=%Version% /DPythonVersion=%Python% "%InsDir%\Salt-Minion-Setup.nsi"
  593. @echo.
  594. @echo.
  595. @echo ======================================================================
  596. @echo Script completed...
  597. @echo ======================================================================
  598. @echo Installation file can be found in the following directory:
  599. @echo %InsDir%
  600. :done
  601. if [%Version%] == [] pause