为了方便在模拟器里部署apk程序,把文件拖到批处理上即可。
push.bat
echo off
::在这里定义好adb.exe所在的文件夹路径
set adb_dir=J:\android\android-sdk-windows\platform-tools
set file=%1
set str=%file%
:loop
set str=%str:*\=%
echo %str% | findstr /i "\\" >nul && goto loop
::echo %file% * %str%
set r=%adb_dir%\adb push %1 sdcard/%str%
%r%
pause
-----------------------------------------------------------------
reinstall.bat
echo off
::在这里定义好adb.exe所在的文件夹路径
set adb_dir=J:\android\android-sdk-windows\platform-tools
set file=%1
set str=%file%
:loop
set str=%str:*\=%
echo %str% | findstr /i "\\" >nul && goto loop
::echo %file% * %str%
set r=%adb_dir%\adb install -r %1
%r%
pause