http://style77125tech.pixnet.net/blog/post/17556680-%5Bandroid%5D-%E4%BD%BF%E7%94%A8adb%E6%8C%87%E4%BB%A4
ADB 系統除錯與連結工具指令
$adb devices (顯示目前有多少個模擬器正在執行)
$adb -s (指定模擬器來操作) Ex:adb -s emulator-5554 install email.apk
$adb install apkfile (安裝 APK 應用程式套件) Ex:adb install email.apk
$adb uninstall package (移除 APK 應用程式套件) Ex:adb uninstall com.android.email
$adb shell (進入 Android 系統指令列模式)
$dmesg (查看 Android Linux Kernel 運作訊息)
ls - 顯示檔案目錄
cd - 進入目錄
rm - 刪除檔案
mv - 移動檔案
mkdir - 產生目錄
rmdir - 刪除目錄
$adb push (複製檔案到 SD 卡) Ex:adb push mp3 /sdcard
$adb pull . (從 Android 系統下載檔案) Ex:adb pull /data/app/com.android.email
$adb logcat (監控模擬器運作紀錄,以Ctrl + c 離開監控模式)
$adb bugreport (產生 adb 除錯報告)
$adb get-state (獲得 adb 伺服器運作狀態)
$adb start-server (啟動 adb 伺服器)
$adb kill-server (關掉 adb 伺服器)
$adb forward tcp:6100 tcp:7100 (更改模擬器網路 TCP 通訊埠)
$adb shell ps -x (顯示 Android 上所有正在執行的行程)
$adb version (顯示 adb 版本)
$adb help (顯示 adb 指令參數)
官方指令集http://developer.android.com/guide/developing/tools/adb.html
http://developer.android.com/tools/help/adb.html
Android Debug Bridge (adb) is a versatile command line tool that lets you communicate with an emulator instance or connected Android-powered device. It is a client-server program that includes three components:
You can find the adb
tool in <sdk>/platform-tools/