ActiveState Community

Hi, is there any guidance to build extension for 5.0*

Posted by ysap on 2008-11-25 11:54

Hi

I am new here and just started using the IDE as well as Edit.
I am thinking to build an extension for a language (called lasso)that does not supported by KOMODO. I have read the post for komodo 4 and tried to follow the steps. But seem not working quite well with komodo 5.

any help?

thanks

ysap

toddw | Tue, 2008-11-25 12:02

There is the following guide for creating a new UDL language extension (which seems to be what you need):
http://community.activestate.com/node/1390

For an example of existing UDL extensions, see maya:
http://svn.openkomodo.com/openkomodo/browse/addons/maya

For example of steps taking to create a SQL language extension, see:
http://community.activestate.com/forum-topic/pl-sql-coide-intelligence

Cheers,
Todd

ysap | Tue, 2008-11-25 12:12

Hi Todd:
Thanks for replying so quikly.
The first link is the one I looked and couldn't follow because there is no luddite under my installation folder. is that because of the version is too high?

I will dig up the other two links.

many thanks

ysap

toddw | Tue, 2008-11-25 12:18

Yes, luddite was removed in a later version of Komodo. The guide does not actually show any usage of luddite, but I've cleaned up the docs a bit to mention luddite has been removed.

Thanks for letting us know.

Cheers,
Todd

ysap | Tue, 2008-11-25 12:24

Looks like the third link is close to what i need to do.
when i tried to following command

koext help gettingstarted

I got the following error:

File "/Applications/Komodo Edit.app/Contents/SharedSupport/sdk/bin/koext", line 46
from os.path import (join, exists, isdir, isfile, abspath, normcase,
^
SyntaxError: invalid syntax

Any idea?

Komodo 5.02

many thanks

toddw | Tue, 2008-11-25 12:36

I believe this is because the Python version (found on your path) that is required to run the koext script is too old.

You can check the version and it's location using:

python -V
which python
whereis python

You'll need to install a newer version of Python and ensure that the newer version is found on your PATH before the older version, or alternatively run the newer version of Python directly:

/usr/local/bin/python /Applications/Komodo Edit.app/Contents/SharedSupport/sdk/bin/koext

Cheers,
Todd

ysap | Tue, 2008-11-25 14:30

Hi Todd:

I solved the error message by upgrading python as you adviced.

The first link is not available any more?

Trying to follow the koext help files, is there any tutorial for udl?

Basicly the language I am trying to use is just some extra tags in html files just like jsp, php. The file extension is still .html. my understanding is I just need to modify the existing html udl that shipped with Komodo?

if that's correct, which file shall I go after?

thanks

toddw | Tue, 2008-11-25 15:24

I've updated the link (the name changed after I'd changed the content, argh!).

I'd suggest modifying one of the existing UDL languages, whichever is closest to your language, such as PHP, and tweak it. Most of the UDL languages included in Komodo are here, you'll want to start from the mainlex udl files, such as "php-mainlex.udl":
http://svn.openkomodo.com/openkomodo/browse/openkomodo/trunk/src/udl/udl

Here is some additional links about UDL:
http://docs.activestate.com/komodo/5.0/udl.html
http://blogs.activestate.com/ericp/2007/01/kid_adding_a_ne.html

Additional UDL forum messages that may provide relevant info and examples:
http://community.activestate.com/forum-topic/html-udl-and-code-intellige...
http://community.activestate.com/forum-topic/komodo-html-template

Cheers,
Todd