Getting Started with the Dev Environment

Developer Environment for Complete UI Requirements

  • Apache Ant 1.6.5
  • Java 1.5 or greater (for running tests)
  • An HTTP server to serve the files (IIS recommended for running the tests currently)
  • MySQL
  • PHP 4+/ASP Classic

Getting the Samples Running

1) Check out Complete UI.

It is recommended that if you are doing your own development that you use either Git or Subversion.

svn checkout http://completeui.googlecode.com/svn/trunk/ completeui
git clone git://github.com/nitobi/completeui.git

2) Setup an Virtual Directory pointing at the root of the repository with your web server of choice (Apache and IIS have been tested).

2a) (Ubuntu Linux only) Ubuntu out of the box does not have the proper mime type for xsl or xslt files. The mime type application/xml must be added to the mime.type directory located in /etc.

3) Load the sql file into the MySQL database. The sql file is in samples/server folder and is called NitobiSampleDatabases.sql.

4) Edit the gethandler and savehandler of a particular sample so that it connects to the database. The gethandlers have names like load_data.php, getNextRecord.asp, or lookuphandler.asp. The savehandlers are usually named saveData.php.

Understanding the File Structure

Currently the file hierarchy is setup as follows:

  • build - ANT files for the public build process. This obfuscates and compresses the js files so that they can be used on public facing sites. This also includes the js for the component
  • samples - This is the sample code that exists for the component.
  • src - The unobfuscated source code which can be broken down into the following components:
    • client
      • component
        • css - The CSS that is used for the component style
        • js - The javascript of the component
        • xml - The XML for the component
        • xsl - The XSL for the component
    • server
      • backend
  • test
    • client
    • functional - This is where the current functional tests exist.
  • testframework - The files that are part of the test suite. We use selenium for testing.

Building with Ant

1) Ensure you have Ant installed and ready to go. See this page if you need help: http://en.wikibooks.org/wiki/Programming:Apache_Ant/Getting_Started

2) Open up a command window/terminal and change the directory so it points to the build directory.

3) Type in 'ant'.

4) The new obfuscated js files will made in the dist folder of the root folder.

page revision: 7, last edited: 1237574088|%e %b %Y, %H:%M %Z (%O ago)
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License