ONLamp.com
oreilly.comSafari Books Online.Conferences.

advertisement


Komodo 3.5 for Dynamic Languages
Pages: 1, 2

Code Control

An essential part of any sizable software development project is controlling the code, in the form of organizing it well, easily seeing its structure, and being able to store and track revisions to that code. Komodo makes it possible to do all of this without leaving the IDE, as it has built-in browsing of projects, code, and objects, as well as hooks to version control systems.



In the upper-lefthand corner of the IDE, a "Project" tab displays all open projects with their constituent files. Double-clicking on any listed file opens it in the righthand pane. Some IDEs that I have tried and abandoned make it difficult to import existing files' trees as a new project within the IDE. It's as if their designers refuse to consider that programmers may have already done some coding before choosing that IDE. Komodo instead offers a much-appreciated "Import from File System" feature that can quickly make existing code efforts visible within Komodo.

The other tab in the upper-lefthand corner, labeled "Code," allows browsing of the source structure within the code files. For PHP projects, it displays included and required files, global variables, and function names, as well as objects, if any. For Perl projects, it displays modules, too. These clickable lists provide a fast way to jump around the code. Sadly, there is a lack of coordination between the Code browser and the other panes. Clicking on a different source file tab in the righthand pane should show that code in the Code browser pane as well, but it doesn't. Even opening a new project doesn't change the Code browser's contents. That is because the Code browser in the current version is not aware of projects, and only shows files opened in the editor. Apparently that is an enhancement slated for the future.

Unlike the browsing of projects and source files, object browsing requires the use of the Tools > Object Browser menu, which seems nonintuitive to me. It would be better if it were located as a third tab in the upper lefthand corner.

The Professional edition of Komodo facilitates source code revisioning by allowing the user to perform all conventional versioning tasks (check-in, check-out, and differences) using several popular code version control systems: CVS, Perforce, and now, with version 3.1, Subversion. Komodo can monitor the repositories and their files, so as to indicate any changes from other users. It is also possible to set up a remote CVS repository and interact with it securely via SSH.

Other Features

Komodo has more capabilities than a single article can explore in depth. I would be remiss to not mention some of them. One real boon is the built-in browser, which allows previewing of HTML, XML, and CSS files, and can thereby save considerable time and frustration from switching back and forth from CGI source code to a web browser to see the results.

Regular expressions (regexes) are a powerful tool in the hands of a skilled programmer, and particularly useful when performing text processing. Perl and PHP both provide solid support for regexes, and Komodo, in like spirit, does the same. In addition to regexes in search-and-replace, as noted earlier, Komodo has a utility that allows you to try various regexes to see how (or if) they match. There are several match type modes: Match, Match All, Split, Replace, and Replace All. In addition, there are modifiers, including case insensitivity. Unfortunately, ActiveState should have named this utility the "Regex Toolkit," but instead chose "Rx Toolkit," which makes it sound like a doctor's medicine bag or a pharmacist's toolkit. To make matters worse, the application's icon is a mortar and pestle--the only instance in the product that I saw of cuteness chosen over clarity.

Komodo features a Visual Package Manager, a web-based management system for installed Perl modules. It is only available in Komodo's Professional edition, as are the Toolbox (a team-shareable storage area for commands, macros, code snippets, etc.) and the ActiveState GUI Builder (for making Tk-based GUI dialogs). For significant application development with a team, integrated source code revisioning alone should make the Professional edition worth the extra cost, but these additional tools would be icing on the cake.

Support

Like most programming tools nowadays, Komodo offers product support in the form of online documentation in HTML and PDF formats, bug tracking, and cookbooks (code collections), in addition to an ActiveState Programmer Network (ASPN).

The online documentation for Komodo is extensive and indexed, with full-text searching. F1 brings up the locally installed "Komodo User Guide." This is a HTML guide of 26 sections ranging from a welcome page to a reference manual. If there is any highlighted text in the current script, pressing Shift + F1 searches the PHP function list for the highlighted string (if the script is PHP), or Googles the highlighted string within www.perldoc.com (if the script is Perl). Ctrl + F1 searches all of Google, regardless of the script's language.

Komodo's user guide contains tutorials on Perl, PHP, Python, Ruby, Tcl, and XSLT--bracketed by a "Feature Showcase" tutorial with 21 subsections explaining many valuables techniques, and a "Run Command Tutorial."

The user guide has a lot of information. The HTML pages use frames, with the lefthand panel used for navigation and the righthand panel displaying contents. It starts with "Welcome to Komodo 3.5.3." Be careful, because if you use your browser's ability to go back to previous pages, and you returned to the welcome page, then the lefthand panel's links no longer work. Also, the fonts and other styling is broken, suggesting that the frame is no longer seeing its intended stylesheet.

If and when the user guide fails to guide the user to an answer, she should next try the ASPN mentioned above. It offers links to dozens of mailing-lists archives, as well as user groups for ActiveState, Perl, PHP, Python, Tcl, .NET Framework, open source, XML and XSLT, and web services. It also has FAQs, tutorials, cookbooks (code recipes), and a bug-tracking system (Bugzilla), as well as documentation for most of those languages, regular expressions, and ActiveState's other programming tools.

Conclusion

Overall, Komodo is a capable and impressive IDE that is well suited for programmers hoping to harness the power of assisted editing, graphical debugging, project versioning and management, and the other tasks essential to developing software in PHP or Perl. However, there are still some shortcomings that I'd like to see future versions address to make Komodo even more attractive than its strongest competitors, such as Eclipse.

ActiveState's Komodo site has links for downloading fully functional editions of Komodo, with free 21-day trial periods. There is also information on upgrade pricing, screenshots, feature lists, release notes, install notes, and other documentation.

Michael J. Ross is a freelance web developer, working primarily with Drupal.


Return to the ONLamp.com.



Sponsored by: