rem Add a new TAP-Win32 virtual ethernet adapter
pushd %~dp0

for /f "tokens=4-5 delims=. " %%i in ('ver') do set VERSION=%%i.%%j
if "%version%" == "10.0" set VERSION=win10
if "%version%" == "6.3" set VERSION=win10
if "%version%" == "6.2" set VERSION=win10
if "%version%" == "6.1" set VERSION=win7

if exist "%SYSTEMDRIVE%\Program Files (x86)\" (
   "driver\x64\tapinstall.exe" install "driver\x64\%version%\OemVista.inf" tap0901
) else (
   "driver\x86\tapinstall.exe" install "driver\x86\%version%\OemVista.inf" tap0901
)
popd