Skip to main content



      Home
Home » Eclipse Projects » Dynamic Languages Toolkit (DLTK) » Creating a project programatically?
Creating a project programatically? [message #1049] Wed, 04 April 2007 19:37 Go to next message
Eclipse UserFriend
What is the correct way to add the default interperter (and it's paths) to a newly created project
(created programatically). Snippet:

....create/open IProject ...setNatures...
IDLTKProject rubyProject = DLTKCore.create(newProject);
List<IBuildpathEntry> entryList = new ArrayList<IBuildpathEntry>();
entryList.add(DLTKCore.newSourceEntry(newProject.getFullPath ().append( "app/controllers")));
....other paths....
entryList.add(ScriptRuntime.getDefaultInterpreterContainerEn try());
rubyProject.setRawBuildpath(entryList.toArray(new IBuildpathEntry[entryList.size()]), null);
....

The paths like "app/controllers" are added correctly but the defaultInterpreter isn't. No
Interpreter paths show up and the Interpreter displays (unbound). Any idea what I'm missing?

Thanks
Mark
Re: Creating a project programatically? [message #1077 is a reply to message #1049] Thu, 05 April 2007 06:10 Go to previous message
Eclipse UserFriend
Originally posted by: mikhail.kalugin.xored.com

Hi,

This code looks right. Please, check following things:
1. Nature for project was set correctly.
2. There are registered interpreters with such nature.
3. Try to update code from CVS. Today I've discovered some bugs with
container resolving and fixed it.

--
Mikhail Kalugin

Mark Howe wrote:
> What is the correct way to add the default interperter (and it's paths)
> to a newly created project (created programatically). Snippet:
>
> ...create/open IProject ...setNatures...
> IDLTKProject rubyProject = DLTKCore.create(newProject);
> List<IBuildpathEntry> entryList = new ArrayList<IBuildpathEntry>();
> entryList.add(DLTKCore.newSourceEntry(newProject.getFullPath ().append( "app/controllers")));
>
> ...other paths....
> entryList.add(ScriptRuntime.getDefaultInterpreterContainerEn try());
> rubyProject.setRawBuildpath(entryList.toArray(new
> IBuildpathEntry[entryList.size()]), null);
> ...
>
> The paths like "app/controllers" are added correctly but the
> defaultInterpreter isn't. No Interpreter paths show up and the
> Interpreter displays (unbound). Any idea what I'm missing?
>
> Thanks
> Mark
>
Previous Topic:Is there DLTK user guide available?
Next Topic:Default Package
Goto Forum:
  


Current Time: Mon May 12 11:57:33 EDT 2025

Powered by FUDForum. Page generated in 0.05183 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top