training-guides/labs/lib/wbatch/template-find_vbm_bat
Roger Luethi 271448cee6 Add Windows batch templates used by wbatch/osbash
The files added in this changeset are used by osbash as templates when
the user requests the creation of Windows batch files.

The names of the templates end on _bat rather than .bat because some
mail providers refuse to deliver .bat files even within archives.

The generated Windows batch files will have the proper extension (.bat).

Change-Id: I5dbed4bc6a4e30b50693208812d3dbfebecb2f19
Partial-Bug: 1312764
Implements: blueprint openstack-training-labs
2014-06-16 14:22:52 +02:00

31 lines
728 B
Batchfile

REM VBoxManage is not in PATH, but this is a good guess
IF EXIST %ProgramFiles%\Oracle\VirtualBox\VBoxManage.exe (
SET PATH=%PATH%;%ProgramFiles%\Oracle\VirtualBox
ECHO.
ECHO %time% Found %ProgramFiles%\Oracle\VirtualBox\VBoxManage.exe
ECHO.
GOTO :vbm_found
)
ECHO.
ECHO %time% Searching %SystemDrive% for VBoxManage, this may take a while
ECHO.
FOR /r %SystemDrive% %%a IN (*) DO (
IF "%%~nxa"=="VBoxManage.exe" (
SET PATH=%PATH%;%%~dpa
ECHO %time% Found %%~dpnxa
GOTO :vbm_found
)
)
ECHO.
ECHO %time% Cannot find VBoxManage.exe (part of VirtualBox) on %SystemDrive%.
ECHO %time% Program stops.
ECHO.
GOTO :terminate
:vbm_found
REM vim: set ai ts=4 sw=4 et ft=dosbatch: