mirror of
https://github.com/0O0o0oOoO00/Alas.git
synced 2026-05-14 07:39:25 +08:00
35 lines
1.1 KiB
Batchfile
35 lines
1.1 KiB
Batchfile
@echo off
|
|
|
|
call loadenv.bat
|
|
|
|
adb connect %SERIAL%
|
|
adb -s %SERIAL% root
|
|
adb -s %SERIAL% shell "mkdir -p %UPLOAD_DIR%"
|
|
|
|
if "%1" == "push" (
|
|
if "%2" == "logger" (
|
|
adb -s %SERIAL% push %BIN_DIR%/crack_logger %UPLOAD_DIR%
|
|
adb -s %SERIAL% shell "chmod +x %UPLOAD_DIR%/crack_logger"
|
|
) else if "%2" == "cracker" (
|
|
if "%3" == "release" (
|
|
adb -s %SERIAL% push %BIN_DIR%/Release-Android-%ARCH%/libcracker.so %GAME_LIB_PATH%
|
|
) else (
|
|
adb -s %SERIAL% push %BIN_DIR%/Debug-Android-%ARCH%/libcracker.so "%GAME_LIB_PATH%"
|
|
)
|
|
) else if "%2" == "patcher" (
|
|
adb -s %SERIAL% push %BIN_DIR%/patchelf %UPLOAD_DIR%
|
|
adb -s %SERIAL% shell "chmod +x %UPLOAD_DIR%/patchelf"
|
|
)
|
|
) else if "%1" == "logger" (
|
|
adb -s %SERIAL% shell "cd %UPLOAD_DIR% && %UPLOAD_DIR%/crack_logger"
|
|
) else if "%1" == "patch" (
|
|
if "%2" == "local" (
|
|
adb -s %SERIAL% shell "%UPLOAD_DIR%/patchelf --local-patch"
|
|
)
|
|
) else if "%1" == "forward" (
|
|
if "%2" == "logger" (
|
|
adb -s %SERIAL% forward tcp:7539 tcp:7539
|
|
) else if "%2" == "cracker" (
|
|
adb -s %SERIAL% forward tcp:23897 tcp:23897
|
|
)
|
|
) |