Created
December 25, 2014 20:28
-
-
Save danvctr/949acc651c9599f8dd38 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
REM This is the "main loop", should be pretty obvious what it does | |
:pingloop | |
ping -n 1 google.com | |
if errorlevel 1 goto fix | |
if errorlevel 0 goto wait | |
REM Make sure you remove the "echo" or it won't do anything lol | |
:fix | |
echo netsh interface set interface "markwireless20" disable | |
echo netsh interface set interface "markwireless20" enable | |
goto wait | |
REM This is a hack I learned back in 'nam that emulates the sleep() fuction of UNIX terminals, which Windows terminals lack... | |
:wait | |
ping -w 5000 127.0.0.1 > nul | |
goto pingloop |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment