{
  "id": "adb",
  "name": "Android Debug Bridge",
  "homepage": "https://developer.android.com/tools/adb",
  "description": "Android Debug Bridge (adb) is a versatile command-line tool that lets you communicate with a device.",
  "icon": "SimpleIcons:android",
  "executables": [
    "adb"
  ],
  "dotfiles": {
    "paths": [
      "~/.android/adbkey.pub"
    ],
    "secret": [
      "~/.android/adbkey"
    ],
    "exclude": [
      "~/.android/avd/",
      "~/.android/cache/",
      "~/.android/build-cache/"
    ]
  },
  "commands": {
    "format": 1,
    "label": "Android Debug Bridge",
    "description": "Talk to Android devices. Device selection flags apply to every subcommand; logcat, forwarding and server management are left out.",
    "quality": "ai-draft",
    "base": "fig:adb",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": false,
      "short_attached": true,
      "short_bundles": false
    },
    "source": [
      {
        "id": "fig",
        "kind": "completion",
        "url": "https://github.com/withfig/autocomplete/blob/master/src/adb.ts",
        "license": "MIT"
      }
    ],
    "field": [
      {
        "id": "serial",
        "label": "Device serial",
        "description": "Target a specific device.",
        "type": "string",
        "option": [
          "-s"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "usb",
        "label": "USB device only",
        "type": "boolean",
        "option": [
          "-d"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "emulator",
        "label": "Emulator (TCP/IP) only",
        "type": "boolean",
        "option": [
          "-e"
        ],
        "sources": [
          "fig"
        ]
      },
      {
        "id": "transport",
        "label": "Transport id",
        "type": "string",
        "option": [
          "-t"
        ],
        "sources": [
          "fig"
        ]
      }
    ],
    "group": [
      {
        "id": "basic",
        "label": "Basic",
        "fields": [
          "serial",
          "usb",
          "emulator"
        ]
      },
      {
        "id": "advanced",
        "label": "Advanced",
        "fields": [
          "transport"
        ]
      }
    ],
    "subcommand": [
      {
        "path": [
          "devices"
        ],
        "label": "List devices",
        "description": "List connected devices.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/adb.ts",
            "license": "MIT"
          }
        ]
      },
      {
        "path": [
          "install"
        ],
        "label": "Install an APK",
        "description": "Push a package to the device and install it. Fast-deploy and agent options are left out.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/adb.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "package",
            "label": "APK file",
            "type": "path",
            "position": 0,
            "path": {
              "kind": "file",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "replace",
            "label": "Replace existing app",
            "type": "boolean",
            "option": [
              "-r"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "test",
            "label": "Allow test packages",
            "type": "boolean",
            "option": [
              "-t"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "downgrade",
            "label": "Allow version downgrade",
            "type": "boolean",
            "option": [
              "-d"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "grant",
            "label": "Grant all runtime permissions",
            "type": "boolean",
            "option": [
              "-g"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "install",
            "label": "Install an APK",
            "fields": [
              "package",
              "replace",
              "grant"
            ],
            "required": [
              "package"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "package",
              "replace",
              "test",
              "downgrade",
              "grant"
            ]
          }
        ]
      },
      {
        "path": [
          "push"
        ],
        "label": "Copy files to device",
        "description": "Copy local files or directories to the device.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/adb.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "local",
            "label": "Local files",
            "type": "path",
            "position": 0,
            "multiple": true,
            "path": {
              "kind": "any",
              "role": "input",
              "must_exist": true
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "remote",
            "label": "Remote path",
            "description": "Destination on the device, for example /sdcard/Download/.",
            "type": "string",
            "position": 1,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "sync",
            "label": "Only newer files",
            "type": "boolean",
            "option": [
              "--sync"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "dry_run",
            "label": "Dry run",
            "type": "boolean",
            "option": [
              "-n"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "push",
            "label": "Push files",
            "fields": [
              "local",
              "remote",
              "sync"
            ],
            "required": [
              "local",
              "remote"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "local",
              "remote"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "sync",
              "dry_run"
            ]
          }
        ]
      },
      {
        "path": [
          "pull"
        ],
        "label": "Copy files from device",
        "description": "Copy files or directories from the device.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/adb.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "remote",
            "label": "Remote paths",
            "type": "string",
            "position": 0,
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "local",
            "label": "Local destination",
            "type": "path",
            "position": 1,
            "path": {
              "kind": "any",
              "role": "output",
              "must_exist": false
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "preserve",
            "label": "Preserve timestamp and mode",
            "type": "boolean",
            "option": [
              "-a"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "pull",
            "label": "Pull files",
            "fields": [
              "remote",
              "local",
              "preserve"
            ],
            "required": [
              "remote",
              "local"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "remote",
              "local",
              "preserve"
            ]
          }
        ]
      },
      {
        "path": [
          "shell"
        ],
        "label": "Run a shell command",
        "description": "Run a command on the device, or open an interactive shell when none is given.",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/adb.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "command",
            "label": "Command",
            "description": "Command and arguments; leave empty for an interactive shell.",
            "type": "string",
            "position": 0,
            "multiple": true,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "no_stdin",
            "label": "Do not read stdin",
            "type": "boolean",
            "option": [
              "-n"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "no_pty",
            "label": "Disable pty allocation",
            "type": "boolean",
            "option": [
              "-T"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "shell",
            "label": "Run a command",
            "fields": [
              "command"
            ],
            "required": [
              "command"
            ]
          },
          {
            "id": "interactive",
            "label": "Interactive shell",
            "fields": [],
            "required": []
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "command"
            ]
          },
          {
            "id": "advanced",
            "label": "Advanced",
            "fields": [
              "no_stdin",
              "no_pty"
            ]
          }
        ]
      }
    ]
  }
}
