Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6ffacae3 authored by Robert Ly's avatar Robert Ly
Browse files

Doc change: Tools section of the dev guide restructuring

Change-Id: I747dfc71e25f76b42476cd7de3c7087aa4e90850
parent 6dd4b14a
Loading
Loading
Loading
Loading
+364 −0
Original line number Original line Diff line number Diff line
page.title=android
@jd:body

<p>{@code android} is an important development tool that lets you:</p>

  <ul>
    <li>Create, delete, and view Android Virtual Devices (AVDs). See <a href= 
    "{@docRoot}guide/developing/devices/managing-avds-cmdline.html">
    Creating and Managing AVDs on the Command Line</a>.</li>

    <li>Create and update Android projects. See <a href= 
    "{@docRoot}guide/developing/projects/projects-cmdline.html">Creating and Managing Projects on
    the Command Line</a>.</li>

    <li>Update your Android SDK with new platforms, add-ons, and documentation. See <a href= 
    "{@docRoot}sdk/adding-components.html">Adding SDK Components</a>.</li>
  </ul>If you are using Eclipse, the <code>android</code> tool's features are integrated
  into ADT, so you should not need to use this tool directly.

  <h2>Syntax</h2>
  <pre>android [global options] action [action options]</pre>

  <h3>Global Options</h3>

  <dl>
    <dt><code>-s</code></dt>

    <dd>Silent mode: only errors are printed out</dd>

    <dt><code>-h</code></dt>

    <dd>Usage help</dd>

    <dt><code>-v</code></dt>

    <dd>Verbose mode: errors, warnings and informational messages are printed.</dd>
  </dl>

  <h3>AVD actions and options</h3>

  <table>
    <tr>
      <th width="15%">Action</th>

      <th width="20%">Option</th>

      <th width="30%">Description</th>

      <th>Comments</th>
    </tr>

    <tr>
      <td rowspan="6"><code>create avd</code></td>

      <td><code>-n &lt;name&gt;</code></td>

      <td>The name for the AVD.</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-t &lt;targetID&gt;</code></td>

      <td>Target ID of the system image to use with the new AVD. To obtain a list of available
      targets, use <code>android list targets</code></td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-c &lt;path&gt;|&lt;size&gt;[K|M]</code></td>

      <td>The path to the SD card image to use with this AVD or the size of a new SD card image to
      create for this AVD. For example, <code>-c path/to/sdcard</code> or <code>-c
      1000M</code>.</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-f</code></td>

      <td>Force creation of the AVD</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-p &lt;path&gt;</code></td>

      <td>Path to the location at which to create the directory for this AVD's files.</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-s &lt;name&gt;|&lt;width&gt;-&lt;height&gt;</code></td>

      <td>The skin to use for this AVD, identified by name or dimensions. The <code>android</code>
      tool scans for a matching skin by name or dimension in the <code>skins/</code> directory of
      the target referenced in the <code>-t &lt;targetID&gt;</code> argument. For example, <code>-s
      HVGA-L</code></td>

      <td></td>
    </tr>

    <tr>
      <td><code>delete avd</code></td>

      <td><code>-n &lt;name&gt;</code></td>

      <td>The name of the AVD to delete</td>

      <td>Required</td>
    </tr>

    <tr>
      <td rowspan="3"><code>move avd</code></td>

      <td><code>-n &lt;name&gt;</code></td>

      <td>The name of the AVD to move</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-p &lt;path&gt;</code></td>

      <td>Path to the location at which to create the directory for this AVD's files.</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-r &lt;new-name&gt;</code></td>

      <td>New name of the AVD if you want to rename it</td>

      <td></td>
    </tr>

    <tr>
      <td><code>update avd</code></td>

      <td><code>-n &lt;name&gt;</code></td>

      <td>The name of the AVD to move</td>

      <td>Required</td>
    </tr>
  </table>

  <h3>Project actions and options</h3>

  <table>
    <tr>
      <th width="15%">Action</th>

      <th width="20%">Option</th>

      <th width="30%">Description</th>

      <th>Comments</th>
    </tr>

    <tr>
      <td rowspan="5"><code>create project</code></td>

      <td><code>-n &lt;name&gt;</code></td>

      <td>The name for the project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-t &lt;targetID&gt;</code></td>

      <td>Target ID of the system image to use with the new AVD. To obtain a list of available
      targets, use <code>android list targets</code></td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-k &lt;path&gt;|&lt;size&gt;[K|M]</code></td>

      <td>Package namespace</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-a</code></td>

      <td>Name for the default Activity class</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-p &lt;path&gt;</code></td>

      <td>Location of your project directory</td>

      <td>Required</td>
    </tr>

    <tr>
      <td rowspan="5"><code>update project</code></td>

      <td><code>-n &lt;name&gt;</code></td>

      <td>The name of the project to update</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-p &lt;path&gt;</code></td>

      <td>Location path of the project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-l &lt;library path&gt;</code></td>

      <td>Location path of an Android Library to add, relative to the main project</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-s &lt;subprojects&gt;</code></td>

      <td>Update any projects in subfolders such as test projects</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-t &lt;targetID&gt;</code></td>

      <td>Target id to set for the project</td>

      <td></td>
    </tr>

    <tr>
      <td rowspan="3"><code>create-test-project</code></td>

      <td><code>-n &lt;name&gt;</code></td>

      <td>The name of the project</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-p &lt;path&gt;</code></td>

      <td>Location path of the project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-m &lt;main&gt;</code></td>

      <td>The name of the project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td rowspan="2"><code>update-test-project</code></td>

      <td><code>-p &lt;path&gt;</code></td>

      <td>Location path of the project to test, relative to the new project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-m &lt;main&gt;</code></td>

      <td>The main class of the project to test</td>

      <td>Required</td>
    </tr>

    <tr>
      <td rowspan="4"><code>create-lib-project</code></td>

      <td><code>-k &lt;packageName&gt;</code></td>

      <td>(Required) Package name of the library project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-p &lt;path&gt;</code></td>

      <td>Location path of the project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-t &lt;targetID&gt;</code></td>

      <td>Target ID of the library project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-n &lt;name&gt;</code></td>

      <td>The name of the project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td rowspan="3"><code>update-lib-project</code></td>

      <td><code>-p &lt;path&gt;</code></td>

      <td>Location path of the project</td>

      <td>Required</td>
    </tr>

    <tr>
      <td><code>-l &lt;libraryPath&gt;</code></td>

      <td>Location path of an Android Library to add, relative to the main project</td>

      <td></td>
    </tr>

    <tr>
      <td><code>-t &lt;name&gt;</code></td>

      <td>Target ID of the library project</td>

      <td></td>
    </tr>
  </table>

  <h3>Update actions</h3>
  <dl>
  <dt><code>update adb</code></dt>
  <dd>Updates adb to support the USB devices declared in the SDK add-ons.</dd>
   
  <dt><code>update sdk</code></dt>
  <dd>Updates the SDK by suggesting new platforms to install if available.</dd>
+64 −0
Original line number Original line Diff line number Diff line
page.title=dmtracedump
@jd:body


 <p><code>dmtracedump</code> is a tool that gives you an alternate way of generating
  graphical call-stack diagrams from trace log files (instead of using Traceview).</p>
  
  <p>This document is a reference to the available command line options. For more information on generating trace
  logs, see <a href="{@docRoot}guide/developing/debugging/debugging-tracing.html">Profiling with
  Traceview and dmtracedump</a>.</p>

  <p>The usage for <code>dmtracedump</code> is:</p>
  <pre>
dmtracedump [-ho] [-s sortable] [-d trace-base-name] [-g outfile] &lt;trace-base-name&gt;
</pre>

  <p>The tool then loads trace log data from <code>&lt;trace-base-name&gt;.data</code> and
  &lt;trace-base-name&gt;.key. The table below lists the options for dmtracedump.</p>

  <table>
    <tr>
      <th>Option</th>

      <th>Description</th>
    </tr>

    <tr>
      <td><nobr><code>-d&nbsp;<em>&lt;trace-base-name&gt;</em></code></nobr></td>

      <td>Diff with this trace name</td>
    </tr>

    <tr>
      <td><code>-g&nbsp;<em>&lt;outfile&gt;</em></code></td>

      <td>Generate output to &lt;outfile&gt;</td>
    </tr>

    <tr>
      <td><code>-h</code></td>

      <td>Turn on HTML output</td>
    </tr>

    <tr>
      <td><code>-o</code></td>

      <td>Dump the trace file instead of profiling</td>
    </tr>

    <tr>
      <td><code>-d&nbsp;<em>&lt;trace-base-name&gt;</em></code></td>

      <td>URL base to the location of the sortable javascript file</td>
    </tr>

    <tr>
      <td><code>-t&nbsp;&lt;percent&gt;</code></td>

      <td>Minimum threshold for including child nodes in the graph (child's inclusive time as a
      percentage of parent inclusive time). If this option is not used, the default threshold is
      20%.</td>
    </tr>
  </table>
 No newline at end of file
+67 −1291

File changed.

Preview size limit exceeded, changes collapsed.

+14 −0
Original line number Original line Diff line number Diff line
page.title=HPROF Converter
@jd:body

<p>
The <code>hprof-conv</code> tool converts the HPROF file that is
generated by the Android SDK tools to a standard format so you
can view the file in a profiling tool of your choice. </p>

<pre> hprof-conv &lt;infile&gt; &lt;outfile&gt;</pre>

<p>
You can use "-" for <code>&lt;infile&gt;</code> or <code>&lt;outfile&gt;</code>
to specify stdin or stdout.
</p>
+39 −64
Original line number Original line Diff line number Diff line
@@ -10,46 +10,34 @@ includes a variety of other tools for debugging, packaging, and installing your
applications on the emulator. </p>
applications on the emulator. </p>


 <dl>
 <dl>
  <dt><a href="adt.html">Android Development Tools Plugin</a> (for the Eclipse IDE)</dt>
  <dt><a href="{@docRoot}sdk/eclipse-adt.html">Android Development Tools Plugin</a> (for the Eclipse IDE)</dt>
          <dd>The ADT plugin adds powerful extensions to the Eclipse integrated environment, 
          <dd>The ADT plugin adds powerful extensions to the Eclipse integrated environment, 
          making creating and debugging your Android applications easier and faster. If you
          making creating and debugging your Android applications easier and faster.</dd>          
          use Eclipse, the ADT plugin gives you an incredible boost in developing Android
          applications.</dd>
  <dt><a href="emulator.html">Android Emulator</a></dt>
  <dt><a href="emulator.html">Android Emulator</a></dt>
    <dd>A QEMU-based device-emulation tool that you can use to design,
    <dd>A QEMU-based device-emulation tool that you can use to design,
    debug, and test your applications in an actual Android run-time environment. </dd>
    debug, and test your applications in an actual Android run-time environment. </dd>


  <dt><a href="avd.html">Android Virtual Devices (AVDs)</a></dt>

    <dd>Virtual device configurations that you create, to model device
  <dt><a href="bmgr.html">bmgr</a></dt>
        characteristics in the Android Emulator. In each configuration, you can

        specify the Android platform to run, the hardware options, and the
    <dd>A shell tool you can use to interact with the Backup Manager on Android devices
        emulator skin to use. Each AVD functions as an independent device with
    supporting API Level 8 or greater. It provides commands to invoke backup and restore operations
        it's own storage for user data, SD card, and so on. </dd>
    so that you don't need to repeatedly wipe data or take similar intrusive steps in order to test

    your application's backup agent. These commands are accessed via the adb shell.
 <dt><a href="hierarchy-viewer.html">Hierarchy Viewer</a></dt>
    <dd>The Hierarchy Viewer tool allows you to debug and optimize your user interface.
        It provides a visual representation of your layout's hierarchy of Views and a magnified inspector
        of the current display with a pixel grid, so you can get your layout just right.
    </dd>  
    </dd>  
    
    
 <dt><a href="layoutopt.html">layoutopt</a></dt>
 <dt><a href="layoutopt.html">layoutopt</a></dt>
    <dd>This tool lets you quickly analyze your application's layouts for
    <dd>This tool lets you quickly analyze your application's layouts in order to
efficiency.
    optimize them for efficiency.
    </dd>
    </dd>



	  <dt><a href="draw9patch.html">Draw 9-patch</a></dt>
	  <dt><a href="draw9patch.html">Draw 9-patch</a></dt>
	    <dd>The Draw 9-patch tool allows you to easily create a 
	    <dd>The Draw 9-patch tool allows you to easily create a 
	    {@link android.graphics.NinePatch} graphic using a WYSIWYG editor. It also previews stretched 
	    {@link android.graphics.NinePatch} graphic using a WYSIWYG editor. It also previews stretched 
	     versions of the image, and highlights the area in which content is allowed.
	     versions of the image, and highlights the area in which content is allowed.
	    </dd>
	    </dd>
			
			
  <dt><a href="ddms.html" >Dalvik Debug Monitor
      Service</a> (ddms)</dt>
        <dd>Integrated with Dalvik, the Android platform's custom VM, this tool
        lets you manage processes on an emulator or device and assists in debugging.
        You can use it to kill processes, select a specific process to debug,
        generate trace data, view heap and thread information, take screenshots
        of the emulator or device, and more. </dd>


  <dt><a href="adb.html" >Android Debug Bridge</a> (adb)</dt>
  <dt><a href="adb.html" >Android Debug Bridge</a> (adb)</dt>
                  <dd>The adb tool lets you install your application's .apk files on an
                  <dd>The adb tool lets you install your application's .apk files on an
@@ -58,45 +46,28 @@ efficiency.
                  on an Android emulator or device.
                  on an Android emulator or device.
                <p>This is located in {@code &lt;sdk&gt;/platform-tools/}.</p></dd>
                <p>This is located in {@code &lt;sdk&gt;/platform-tools/}.</p></dd>


  <dt><a href="aapt.html">Android Asset
  <dt><a href="hprof-conv.html">hprof-conv</a></dt>
          Packaging Tool</a> (aapt)</dt>
                  <dd>The aapt tool lets you create .apk files containing the binaries and
                  resources of Android applications.</dd>


  <dt><a href="aidl.html" >Android Interface
    <dd>A tool that converts the HPROF file that is generated by the Android SDK tools to a
  Description Language</a> (aidl)</dt>
    standard format so you can view the file in a profiling tool of your choice.</dd>
            <dd>Lets you generate code for an interprocess interface, such as what
            a service might use.</dd>
    
    
  <dt><a href="adb.html#sqlite">sqlite3</a></dt>
  <dt><a href="sqlite3.html">sqlite3</a></dt>
      <dd>Included as a convenience, this tool lets you access the SQLite data 
      <dd>Included as a convenience, this tool lets you access the SQLite data 
      files created and used by Android applications.</dd>
      files created and used by Android applications.</dd>


  <dt><a href="traceview.html" >Traceview</a></dt>
  <dt><a href="mksdcard.html">mksdcard</a></dt>
            <dd> This tool produces graphical analysis views of trace log data that you
            can generate from your Android application. </dd>

  <dt><a href="othertools.html#mksdcard">mksdcard</a></dt>
            <dd>Helps you create a disk image that you can use with the emulator, 
            <dd>Helps you create a disk image that you can use with the emulator, 
                      to simulate the presence of an external storage card (such as an SD card).</dd>
                      to simulate the presence of an external storage card (such as an SD card).</dd>
                      
                      
  <dt><a href="othertools.html#dx">dx</a></dt>
                  <dd>The dx tool rewrites .class bytecode into Android bytecode
                                          (stored in .dex files.)</dd>

  <dt><a href="monkey.html">UI/Application 
  <dt><a href="monkey.html">UI/Application 

  Exerciser Monkey</a></dt>
  Exerciser Monkey</a></dt>
      <dd>The Monkey is a program that runs on your emulator or device and generates pseudo-random
      <dd>A program that runs on your emulator or device and generates pseudo-random
      streams of user events such as clicks, touches, or gestures, as well as a number of system-
      streams of user events such as clicks, touches, or gestures, as well as a number of system-level events.
      level events.  You can use the Monkey to stress-test applications that you are developing,
      You can use the Monkey to stress-test applications that you are developing, in a random yet repeatable manner.</dd>
      in a random yet repeatable manner.</dd>



  <dt><a href="monkeyrunner_concepts.html">monkeyrunner</a></dt>
  <dt><a  href="android.html">android</a></dt>
  <dd>
    The monkeyrunner tool provides an API for writing Python programs that control an Android device
    or emulator from outside of Android code.
  </dd>
  <dt><a  href="othertools.html#android">android</a></dt>
            <dd>A script that lets you manage AVDs and generate <a
            <dd>A script that lets you manage AVDs and generate <a
                        href="http://ant.apache.org/" title="Ant">Ant</a> build files that
                        href="http://ant.apache.org/" title="Ant">Ant</a> build files that
                        you can use to compile your Android applications. </dd>
                        you can use to compile your Android applications. </dd>
@@ -105,5 +76,9 @@ efficiency.
            <dd>An important .apk optimization tool. This tool ensures that all uncompressed data starts
            <dd>An important .apk optimization tool. This tool ensures that all uncompressed data starts
            with a particular alignment relative to the start of the file. This should always be used
            with a particular alignment relative to the start of the file. This should always be used
            to align .apk files after they have been signed.</dd>
            to align .apk files after they have been signed.</dd>
            

    

</dl>
</dl>
Loading