Skip to content

Instantly share code, notes, and snippets.

Created August 3, 2017 14:24
What would you like to do?
Toggle Hyper-V util (docker vs avd-haxm)
@echo off
echo Select hypervisor launch tipe (auto/off):(A/O)
set INPUT=
set /P INPUT=Type input: %=%
If /I "%INPUT%"=="a" goto auto
If /I "%INPUT%"=="o" goto off
echo Incorrect input & goto InputToggle
bcdedit /set hypervisorlaunchtype auto
goto InputReboot
bcdedit /set hypervisorlaunchtype off
goto InputReboot
echo Do you want to reboot now?(Y/N)
set INPUT=
set /P INPUT=Type input: %=%
If /I "%INPUT%"=="y" goto rebootyes
If /I "%INPUT%"=="n" goto rebootno
echo Incorrect input & goto InputReboot
echo Done. Rebooting now to apply changes.
shutdown.exe /r /t 08
goto end
echo Done. Reboot manually to apply changes.
goto end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment