Created
August 24, 2018 13:43
-
-
Save felipebaltazar/3b2e3388aae2801e71867db9bf58a042 to your computer and use it in GitHub Desktop.
Bat to restart adb server
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 | |
echo ===========Adb server restart script=========== | |
echo Author: Felipe Baltazar | |
echo Github:https://github.com/felipebaltazar | |
echo Creation Date: 24/08/2018 | |
echo. | |
echo. | |
echo ====================Status===================== | |
echo Checking adb default path... | |
call CD %HomePath%\AppData\Local\Android\sdk\platform-tools | |
echo. | |
if %ERRORLEVEL% == 0 goto :restartAdb | |
echo ====================Status===================== | |
echo Error.. Exited with status: %errorlevel% | |
echo ->You need abd to continue... | |
echo. | |
goto :endfail | |
:restartAdb | |
echo ====================Status===================== | |
echo Status:Restarting adb server | |
adb kill-server | |
adb start-server | |
echo. | |
goto :endsucess | |
:endsucess | |
echo ====================Status===================== | |
echo Done! | |
goto :endofscript | |
:endfail | |
echo ====================Status===================== | |
echo Status: Error! | |
:endofscript | |
pause |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment