usage.rst 1.86 KB
Newer Older
Brian Douglass's avatar
Brian Douglass committed
1 2 3 4 5 6 7 8 9 10
.. _usage:

Usage
=====

Getting Started
---------------

You can get started with using clickable with an existing Ubuntu Touch app.
You can use clickable with apps generated from the old Ubuntu Touch SDK IDE
Brian Douglass's avatar
Brian Douglass committed
11
or you can start fresh by running ``clickable create``.
Brian Douglass's avatar
Brian Douglass committed
12 13

To run the default set of sub-commands, simply run ``clickable`` in the root directory
14 15
of your app's code. Clickable will attempt to auto detect the
:ref:`build template <build-templates>` and other configuration options.
Brian Douglass's avatar
Brian Douglass committed
16 17 18

Running the default sub-commands will:

Brian Douglass's avatar
Brian Douglass committed
19 20 21 22 23
1) Clean the build directory (by default the build directory is ``./build/``)
2) Compile the app
3) Build the click package (can be found in the build directory)
4) Install the app on your phone (By default this uses adb, see below if you want to use ssh)
5) Kill the running app on the phone
Brian Douglass's avatar
Brian Douglass committed
24 25
6) Launch the app on your phone

26 27 28 29 30 31 32
Configuration
-------------
If you need more advanced usage options, you may specify a configuration file
in the :ref:`clickable.json format <clickable-json>` with ``--config``. If not
specified, clickable will look for an optional configuration file called
``clickable.json`` in the current directory.

Brian Douglass's avatar
Brian Douglass committed
33 34
.. _ssh:

Brian Douglass's avatar
Brian Douglass committed
35 36 37 38 39
Connecting to a device over ssh
-------------------------------

By default the device is connected to via adb.
If you want to access a device over ssh you need to either specify the device
40
IP address or hostname on the command line (ex: ``clickable logs --ssh 192.168.1.10`` ) or you
Brian Douglass's avatar
Brian Douglass committed
41 42 43
can use the ``CLICKABLE_SSH`` env var.

.. _multiple-devices:
Brian Douglass's avatar
Brian Douglass committed
44 45 46 47 48 49 50

Multiple connected devices
--------------------------

By default clickable assumes that there is only one device connected to your
computer via adb. If you have multiple devices attached to your computer you
can specify which device to install/launch/etc on by using the flag
Brian Douglass's avatar
Brian Douglass committed
51 52
``--serial-number`` or ``-s`` for short. You can get the serial number
by running ``clickable devices``.