App Development Starter Kit

Deprecation Warning! The content below is only applicable for use within deprecated 1.x versions of Rally's App SDK. Use of the component(s) and/or code on this page is not supported. To develop custom apps within our current environments, please see App SDK 2.0 documentation.

The App Development Starter Kit was developed to allow you to create apps using the same tools that Rally uses internally.  For more information on the basics of app development see Getting Started.

Software requirements

java (required for jslint support; recommended)
http://www.oracle.com/technetwork/java/javase/downloads/jdk-6u30-download-1377139.html
Ensure java is included in the global PATH.

ruby
http://rubyinstaller.org/downloads/ (Windows only- comes with OSX)
The starter kit has been tested against v1.8.7 of ruby.

rake
http://rake.rubyforge.org/
Rake is a build tool for ruby and can be installed from the command line:

> gem install rake

Contents

Download and uncompress the starter kit from the link located at the bottom of this page.

The starter kit contains the following items:

  • Examples: Example apps that can be built using the toolkit
  • lib: New app templates and the jslint4java jar file
  • Rakefile: Contains targets for building apps

Rakefile usage

The rakefile is used to manage all parts of the app development process.  The following targets are defined:

> rake -T
rake combine # Merge all css and js into one app html file
rake default # Default task (equivalent to deploy)
rake deploy # Run jslint and combine
rake jslint # Runs JSLint on all app JavaScript files
rake new[app_name] # Create a new app

 

Create an app

This task creates a new directory with an html, css, and js file for app development.

> rake new[AppName]

Creating directory AppName...
Creating AppName.css...
Creating AppName.js...
Creating AppName.template.html...

Add any app styles to the css file and any app javascript to the newly created js file.  The template.html file references both of them so running, debugging, and testing your app is as simple as opening the template.html file in Chrome or Firefox.

Note that in order to support running outside of Rally, the SDK is included as a fully qualified URL from rally1.rallydev.com. On-premises users should adjust the template.html file to reference the correct server. More information on using apps outside of Rally can be found here.

Also note that the SDK is included in debug mode for development (?debug=true). More information on SDK query string parameters can be found here.

 

JSLint

This task examines your javascript and can help detect common problems like missing semicolons. Note this task requires java.

> rake jslint

Running jslint...

-------JSLint output for AppName.js--------------
jslint:AppName.js:3:10:Missing semicolon.

 

Deploy To Rally

Once development and debugging is complete it is time to combine the html, css, and js files into one html file which can be easily pasted into a Rally custom tab.

> rake combine

Processing AppName.template.html...
Concatenating AppName.css...
Concatenating AppName.js...

Creating merged app html file AppNameApp.html...
AppNameApp.html successfully created!

Alternatively, you can invoke the deploy target. This is the same as combine but also runs jslint. This is also the default and can be invoked by typing rake.

> rake deploy

Running jslint...

-------JSLint output for AppName.js--------------

Processing AppName.template.html...
Concatenating AppName.css...
Concatenating AppName.js...

Creating merged app html file AppNameApp.html...
AppNameApp.html successfully created!

Paste the contents of the generated App.html file into a Rally custom tab to begin using it in your Rally workspace.

Note that the generated App.html file no longer references the App SDK using a fully qualified URL and so can no longer be run outside Rally.  Instead, the SDK will be loaded from the Rally server in which the app is running.

Download Code: 

Feedback

Need more help? The CA Agile Central Community is your one-stop shop for self-service and support. To submit feedback or cases to CA Agile Central Support, find answers, and collaborate with others, please join us in the CA Agile Central Community.