3
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

adbコマンド

Last updated at Posted at 2024-11-05

🎀 はじめに

(私が)よく使うadbコマンドをまとめます
システムアプリ(プリインストールアプリ)を作成時に使用しました

端末に接続 / 接続解除

$ adb connect IPアドレス
$ adb disconnect IPアドレス

adb接続しているデバイス一覧

$ adb devices

端末再起動

$ adb reboot

🖥️ adbコマンド

adbコマンドを使うためにはUnixシェルにアクセスする必要があります

$ adb shell

もしくは、下記のコマンドの前にadb shellをつけてください

$ adb sell pm disable-user アプリパッケージ名

システムアプリの無効化

$ pm disable-user アプリパッケージ名

システムアプリの有効化

$ pm enable アプリパッケージ名

システムアプリがどうか

$ dumpsys package アプリパッケージ名

システムアプリのアンインストール

$ pm uninstall アプリパッケージ名
もしくは
$ pm uninstall --user 0 アプリパッケージ名

アプリ強制終了

$ am force-stop アプリパッケージ名

スクリーンセーバーが有効化どうか

1: 有効
0: 無効

$ settings get secure screensaver_enabled

スクリーンセーバーを表示

$ am start -n "com.android.systemui/.Somnambulator"

設定しているアラーム

$ dumpsys alarm | grep アプリパッケージ名

キーイベント

$ input keyevent KEYCODE_DPAD_RIGHT
$ input keyevent KEYCODE_DPAD_LEFT

🚗 最後に

随時追加予定です

3
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
3
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?