Skip to content

Commit

Permalink
Update brevent.bat
Browse files Browse the repository at this point in the history
  • Loading branch information
EDISON,Z authored Jun 6, 2017
1 parent f03afab commit 612c7fc
Showing 1 changed file with 0 additions and 30 deletions.
30 changes: 0 additions & 30 deletions brevent.bat
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,11 @@
title Brevent-bat By Edison.Z
echo Brevent-bat By Edison.Z
echo Github:https://github.com/EDISON-Z/Brevent-bat
:: BatchGotAdmin
:-------------------------------------
REM --> Check for permissions
IF "%PROCESSOR_ARCHITECTURE%" EQU "amd64" (
>nul 2>&1 "%SYSTEMROOT%\SysWOW64\cacls.exe" "%SYSTEMROOT%\SysWOW64\config\system"
) ELSE (
>nul 2>&1 "%SYSTEMROOT%\system32\cacls.exe" "%SYSTEMROOT%\system32\config\system"
)

REM --> If error flag set, we do not have admin.
if '%errorlevel%' NEQ '0' (
echo Requesting administrative privileges...
echo 正在请求管理员权限...
goto UACPrompt
) else ( goto gotAdmin )

:UACPrompt
echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs"
set params = %*:"=""
echo UAC.ShellExecute "cmd.exe", "/c ""%~s0"" %params%", "", "runas", 1 >> "%temp%\getadmin.vbs"

"%temp%\getadmin.vbs"
del "%temp%\getadmin.vbs"
exit /B

:gotAdmin
pushd "%CD%"
CD /D "%~dp0"
:--------------------------------------
echo Please connect your devices, and make sure you are already enable USB Debug Mode
echo 请连接设备,并开启USB调试
pause
adb devices
pause
adb devices
adb -d shell sh /sdcard/Android/data/me.piebridge.brevent/brevent.sh

pause

0 comments on commit 612c7fc

Please sign in to comment.