Christian Hent

Nooku tutorial part 1: How to setup nooku framework

I. What is Nooku?
Nooku Framework [1] is a rapid extension development platform for Joomla, written in PHP 5.2 and is released as GPL. It aims to speed up the creation and maintenance of Joomla extensions, to eliminate repetitive coding, and add power, flexibility and fun. The main goal for Nooku Framework 1.0 is Joomla extension development. Nooku should make it easy to quickly develop flexible MVC extensions, and provide the necessary elements to handle the most common tasks; building grids and forms, manipulating data, providing for extensibility. After the release of Nooku Framework 1.0 the focus will shift to building of applications for Joomla! or even complete stand-alone web applications.

II. How to set it up?
Make sure you have PHP 5.2 or later and use MySQLi in Joomla. You can choose this during Joomla's installation, or manually edit var $dbtype = 'mysqli'; in configuration.php. This does not have any impact on existing extensions. Nooku uses the MySQL connection created by Joomla's DB connector and are pushing that into the MySQLi connector (on a mysql level both resources are the same). The nooku developers recommend reading [2] for more background info.

For the moment the nooku developers choose not to offer downloadable packages yet
because the framework is still heavily under development. Once 0.7 has been released, they plan start offering downloadable packages. Until then, you can easily build your own package though.

Here are some instructions for Windows users. Sure, for advanced users there are other & better ways to make the plugin to work and keep it updated (see below: Phing).

Try WAMP for a dev environment. Then you must download Nooku from SVN [3]:

- download and install a svn client
- make directory for svn *download* [D:\mySVN\koowa]
- make directory for svn *export* [D:\webRAD\koowa]
- after that, do in [D:\mySVN\koowa] a svn checkout from [3]
- after that, *export* with your svn client in [D:\mySVN\koowa\trunk] the [\code] directory to [D:\webRAD\]

Next, rename the directory [D:\webRAD\code] in [D:\webRAD\plg_koowa]. Now zip it and just install the plugin similar to other plugins in Joomla!. At last, you must activate the plugin to work. That's the end of it and now you can begin with coding.

Although you could make zip packages of Nooku manually, that is not recommended. As Nooku grows, building packages might become more complex than just zipping. Files may need be downloaded from different locations, moved around etc. Humans can make errors, so it's always better to use scripts for these sort of tasks.

Phing is a PHP based command line application that allows you to easily create packaging scripts. It's similar to applications like Ant and GNU Make. Nooku Framework provides build scripts you can run to build the packages.

Follow these steps to build installable packages of Nooku Framework:

- Install these PEAR packages:
--- phing http://phing.info/trac/wiki/Users/Download
--- subversion http://pear.php.net/package/VersionControl_SVN/download
- Checkout the scripts/build folder in the branch you want to use (The current stable branch of koowa is in /releases/0.6, so that would make /releases/0.6/scripts/build)
- Edit build.properties if desired
- Run 'phing' in that folder
- A tar.gz package should now be created

If you now ask yourself how you can ship Nooku with your extension I have at the moment only one answer. Preferably, your users should install the framework plugin separately first. The install process of the Nooku framework extension is very simple and requires little to no configuration, so it shouldn't be hard for any user. The plan for the future is to add an installer to the framework that deals with dependencies and all that. So the user will install Nooku once, and then all nooku-based extensions will use nooku's installer.

III. Please bear in mind
Nooku works stable and great! But, please don't install nooku on live servers when you do not exactly know what you do. I can't help you if you screw up a live site. Please bear in mind, nooku framework is at the moment not official released to the masses. It makes in my opinion not sense to ask in any Joomla forums for support.

IV. Additional Infos and Links
This was first part of my nooku tutorials series. The second part covers then the developing of a simple backend/frontend component and will be published in the next days. I am not affiliated with the developers of nooku from joomlatools.eu. But I maintain, this developers (Mathias and Johan) are one of the friendliest that I've ever met across in the Joomla world and they are very respectable people.

Links:
[1]
http://www.nooku.org/en/framework.html
[2]
http://devzone.zend.com/node/view/id/686
http://dev.mysql.com/doc/refman/5.0/en/apis-php-mysqli.html
[3]
http://nooku-framework.svn.sourceforge.net/svnroot/nooku-framework

Views: 931

Tags: nooku

Marco Barbosa Comment by Marco Barbosa on November 7, 2009 at 9:00am
Very good chent!

I like the item III ;D

Looking forward for the next parts!
Oleg Nesterov Comment by Oleg Nesterov on November 8, 2009 at 3:08pm
Thanks for the post. One note: since this tutorials is for Nooku framework beginners it will be great if you mention that koowa = nooku framework somewhere earlier than the svn paths.
Helio Alves Comment by Helio Alves on November 8, 2009 at 9:45pm
Hi Chent,

Thank you very much for this tutorial, I'm a beginner, started a couple of days ago with Nooku but there is not a lot of documentation and tutorials for beginners so this one if very appreciated :)

I'm looking far for the part 2 :)

Great job
Christian Hent Comment by Christian Hent on November 9, 2009 at 12:44am
Thank you Oleg,

I added in the first paragraph the sentence: Nooku Framework is the official name, Koowa the codename.
HienNH Comment by HienNH on March 8, 2011 at 9:46pm
Thank Christian, waiting for the second part!
FrankM Comment by FrankM on May 11, 2011 at 10:36am
Nooku framework is really robust.
NGuyen Duc Giang Comment by NGuyen Duc Giang on May 30, 2011 at 9:26pm
Great, thanks for sharing
Klas Comment by Klas on June 2, 2011 at 5:40pm
hm, looks this isn't valid anymore,  would be great if oyu could update it with more current way to install

Comment

You need to be a member of All Together, As A Whole to add comments!

Join All Together, As A Whole

Badge

Loading…

© 2012   Created by Amy Stephen.

Badges  |  Report an Issue  |  Terms of Service