tree: f63b81db06e6f67bad6be4126ccca6e8eda380eb [path history] [tgz]
  1. bin/
  2. lib/
  3. test/
  4. tool/
  5. .gitignore
  7. pubspec.lock
  8. pubspec.yaml


This utility tool is used by LUCI infrastructure to manage device health for Flutter LUCI swarming bots.

It offers support for different host platforms: linux, mac and windows, and different devices: android and iOS.


Different devices require different tools to be in the path beforehand.


  • adb


  • idevice_id
  • idevicediagnostics
  • xcrun


This tool is meant to be published as an AOT compiled binary distributed via CIPD.

Build the tool for different host platforms on corresponding machines. It will automatically download a suitable version of Dart to build the binary.

To create the CIPD package, make sure that the build/ folder does not exist.

Auto build

Every new commit will trigger pre-submit builders to auto build a new version for different platforms without any tag/ref.

When a new commit is submitted, post-submit builders will trigger a new version with a tag of commit_sha, and a ref of staging.

Manual build

Running tool/ or tool/build.bat will build an executable binary in the build folder. Then push to cipd by running

cipd create -in build                   \
  -name flutter/device_doctor/<os>-amd64 \
  -ref <ref>                     \
  -tag sha_timestamp:<revision>_<timestamp>
  • os: linux, mac, or windows.
  • ref: release or staging

How to use

device_doctor is the executable binary, and can be called

/path/to/device_doctor --action <healthcheck|recovery|properties> --device-os <android|ios>

Use /path/to/device_doctor --help to learn more.

Note: this tool is assuming one connected device on each host, but can be easily extended to support multiple devices.