Orchard.Device (orchard v0.1.7)

View Source

Module for managing physical Apple devices using AXe CLI.

Summary

Functions

Finds a device by its identifier (name or UDID).

Installs an app on the device.

Lists all connected devices.

Runs a command on the specified device.

Uninstalls an app from the device.

Types

t()

@type t() :: %Orchard.Device{
  model: String.t(),
  name: String.t(),
  platform: String.t(),
  state: String.t(),
  udid: String.t(),
  version: String.t()
}

Functions

find(identifier)

@spec find(String.t()) :: {:ok, t()} | {:error, String.t()}

Finds a device by its identifier (name or UDID).

install_app(device, app_path)

@spec install_app(t(), String.t()) :: :ok | {:error, String.t()}

Installs an app on the device.

list()

@spec list() :: {:ok, [t()]} | {:error, String.t()}

Lists all connected devices.

Returns a list of device structs.

run_command(device, command)

@spec run_command(t(), String.t()) :: {:ok, String.t()} | {:error, String.t()}

Runs a command on the specified device.

uninstall_app(device, bundle_id)

@spec uninstall_app(t(), String.t()) :: :ok | {:error, String.t()}

Uninstalls an app from the device.