Building your app in debug mode

Building your app in debug mode will produce an unsigned version of your app, which you can then distribute to others for testing.

You can build your app in one of two modes.

  • Debug mode: Debug mode should be used when you are preparing your app for testing. When you build the app in debug mode, the command packages your resources and plugins together in a .bar file, but does not sign it.

    Debug mode also enables Web Inspector for the app, which allows you to remotely inspect the source code. A prompt displays the URL that you can use to connect to and inspect your app. For more information on using Web Inspector, see Debugging using Web Inspector.

  • Release mode: Release mode should be used at the end of the development cycle when you are preparing your app to be submitted to BlackBerry World. When you build your app in release mode, the command packages your resources and plugins together in a .bar file, then signs the app. For more information, see Building and signing your completed app.

Build your project using the SDK web tool

To build your app in debug mode:

  1. Open BlackBerry WebWorks <version>. A new browser window opens, displaying the BlackBerry 10 WebWorks SDK web tool.
  2. Navigate to your project and click Build.
  3. Select Debug Mode.
  4. Click Build.

The tool packages your app into a .bar file, and places the unsigned copy of the .bar file in the following location: <your_app_project_directory>\platforms\blackberry10\build\device.

Build your project from the command line

To build your app and package it as an unsigned .bar file:

  1. On the command line, navigate to your project folder.
  2. Run the following command:
    webworks build [--debug] [-p|--params <JSON-file>] [-l|--loglevel <level>] 

All parameters are optional. Check the table below for parameter details:

Parameters Description
--debug

Indicates that the app will be built in debug mode. This parameter is optional; --debug is the default build mode.

-p|--params <JSON-file>

A JSON file containing additional parameters to pass to downstream tools.

This argument is optional.

-l|--loglevel <level>

The log level. The level may be one of error, warn, or verbose.

This argument is optional.

Last modified: 2014-12-04



Got questions about leaving a comment? Get answers from our Disqus FAQ.

comments powered by Disqus