1
0

More than 3 years have passed since last update.

adbコマンド

Posted at

Androidアプリを開発するにあたって、
よく使うADBコマンドからたまにしか使わないけど毎回調べてしまうものまとめました。

アプリ(APK)のインストール

デバイスに未インストール

adb install 

インストール済み(上書きインストール)

adb install -r 

インストール済み(ダウングレード)

adb install -d

接続済み端末の確認

adb devices

端末指定

adb -s <device id> * 

device idは接続済み端末の確認のコマンドにて取得
*はinstall, uninstallなど指定した端末に対して行いたいコマンド

ファイルの転送

adb push <転送するファイル名> <転送先のパス>

ファイルの取得

adb pull <取得元のパス>

AlarmManagerの設定時刻

【Android】adbを使ってAlarmManagerの実行予定時間を確認する

adb shell dumpsys alarm | find "<package name>"

ログ取得

adb logcat 

ログクリア

adb logcat -c

ログファイルを取得

adb logcat > hoge.txt

ADBのバージョン

adb version

アプリアンインストール

adb uninstall

文字入力

adb shell input text <入力したい文字列>

インストール済みパッケージリスト

よく使うadbのコマンド

adb shell pm list packages

参考文献

【Android】adbを使ってAlarmManagerの実行予定時間を確認する
よく使うadbのコマンド

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0