> For the complete documentation index, see [llms.txt](https://violetxf.gitbook.io/messengerbot/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://violetxf.gitbook.io/messengerbot/tips/adb.md).

# ADB를 사용할 때

만약 컴퓨터에서 스크립트를 편집하고 ADB를 통해 안드로이드 휴대전화로 파일을 push하는 방식을 선호하는 사용자라면, 다음과 같이 메신저봇이 지원하는 여러가지 Broadcast를 통해 좀 더 효율적으로 작업할 수 있습니다.

[예제 자바 라이브러리를 보려면 클릭하세요.](https://github.com/VioletXF/MessengerBotDebugBridge)

| Actions                                  | Extras                       | Explanations                                                                                  |
| ---------------------------------------- | ---------------------------- | --------------------------------------------------------------------------------------------- |
| com.xfl.msgbot.broadcast.compile         | name: String                 | name이라는 이름을 가진 [Bot](/messengerbot/api2/bot.md)을 컴파일합니다. (name에는 .js와 같은 확장자명이 포함되지 않습니다.)    |
| com.xfl.msgbot.broadcast.set\_bot\_power | name: String, power: Boolean | name이라는 이름을 가진 [Bot](/messengerbot/api2/bot.md)의 전원을 설정합니다. (name에는 .js와 같은 확장자명이 포함되지 않습니다.) |
| com.xfl.msgbot.broadcast.set\_activation | activation: Boolean          | 메신저봇 앱의 활성화 여부를 설정합니다.                                                                        |

## 사용 예시(ADB)

```bash
adb shell am broadcast -a com.xfl.msgbot.broadcast.set_bot_power -p com.xfl.msgbot --es name 브로드캐스트\ 테스트\ 봇 --ez power false
```

위의 예시는 "브로드캐스트 테스트 봇"의 전원을 끕니다.

Tip: ADB에서 봇 이름으로 띄어쓰기를 사용하려면 \\(백슬래시)로 이스케이프해야 합니다.
