IBM Rational Application Developer 9.5 Beta (RAD) was released today. Many things are worth to be noted, but this post will talk about the Apache Cordova support. For more details, visit our Community in IBM developerWorks https://ibm.biz/BdEUiR
Support for plugins other than the official Cordova Plugins Registry.
Rational Application Developer's Cordova projects now have the ability to install plugins from either the local file system or from a Git repository. To add a plugin location in RAD go to Window > Preferences > Cordova > Plugins, in there you will see a table where you can add and remove the plugin locations.
One of the advantages of adding the plugin locations using this preferences page is that locations can be shared among developers, meaning they don't have to manually specify the location. To export these preferences for sharing, go to File > Export and under General category select Preferences. In the Export Preferences wizard make sure you select Cordova preferences. The resultant file can be distributed among developers to be imported as Preferences file.
The Cordova Plugins preferences page contains two Add buttons:
- Add local...: Use it to add a plugin that is stored locally in the file system. Make sure you specify the root location of the plugin where the plugin.xml file resides.
- Add Git...: Use it when you have a plugin that is hosted on a Git SCM server. Make sure you point to the .git location. For instance https://github.com/phonegap/phonegap-facebook-plugin.git
Once the plugin locations are configured in this preferences page, they can be added to Cordova projects in the usual ways.
- When creating a project, in the Configuration page of the New Cordova project wizard in Plugins category.
- In Project properties of a Cordova project, in Plugins category.
In both cases, you can click on Add plugin... and the Add Apache Cordova Plugins dialogue will come up. Here you can select the plugins that come from the official Cordova Plugins Registry or the Plugins that were configured in the Plugins preferences page.
IMPORTANT NOTE: Read this technote for more information about Git CLI client support in RAD Cordova tools http://www-01.ibm.com/support/docview.wss?uid=swg21687322
Depending on your OS, you can do one of the following things to work around this problem.
As stated in the technote, the folders added to the PATH during execution in RAD are
In Windows 7, %SystemRoot% is C:\System.
Create a BAT file in System32 folder named git.bat which delegates the execution to the actual git.exe. Assume Git is installed in C:\Program Files(x86)\Git, the BAT file will contain the following:
“C:\Program Files(x86)\Git\cmd\git.exe” %*
In the technote, it says that the folders added to the PATH during execution are:
Typically, when installing Git on Linux or Mac, it creates a symbolic link in /usr/bin, however if this is not the case then create such symbolic link following these steps:
- Locate the directory where Git is installed. For this example assume Git binary is /opt/git/bin/git.
- Open a Terminal.
- Run the following command
$ ln -s /opt/git/bin/git /usr/bin/git
Cordova CLI upgraded to 4.0.0.
RAD 9.5 Beta has been updated to include Cordova CLI 4.0.0 that offers a number of new features and bug fixes. For more details go to http://cordova.apache.org/announcements/2014/10/16/cordova-4.html
You can verify the version levels of your Cordova locations by going to Window > Preferences > Cordova and selecting the Cordova location in the table.
Network Connections link in Cordova preferences page.
When using Cordova for the first time (meaning creating a Cordova project for the first time) as you are adding platform and plugins support, additional Cordova artifacts need to be downloaded from Internet. If you are behind a proxy, this new Network Connections link comes handy.
Go to Window > Preferences > Cordova and you will see the Network Connections link at the top of the wizard. Click on it and you will be redirected to Network Connections preferences page that is located under General category. In there, you can configure your proxy settings. See this Eclipse help page for details about how to configure your proxy settings.
Links of interest.
- For more information about Cordova tools in RAD, visit our Knowledge Center http://www-01.ibm.com/support/knowledgecenter/SSRTLW_9.5.0/com.ibm.hybrid.mobile.doc/topics/chybridmobileoverview.html
- To find out more about Rational Application Developer V9.5 Beta, visit our Early Program site https://www14.software.ibm.com/iwm/web/cc/earlyprograms/rational/radob2/index.shtml
- To join a discussion or ask questions about Rational Application Developer V9.5 Beta, visit our Beta https://www.ibm.com/developerworks/community/forums/html/forum?id=7ecc4be7-f807-4fa8-811a-6a1a26300fa9
- To learn more about IBM Rational Application Developer, visit our product wiki https://www.ibm.com/developerworks/community/wikis/home?lang=en#!/wiki/Rational%20Application%20Developer%20Wiki