Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » set run configuration programmtical, launch programmatical
set run configuration programmtical, launch programmatical [message #335724] Thu, 23 April 2009 15:25 Go to next message
Jens B. is currently offline Jens B.Friend
Messages: 2
Registered: July 2009
Junior Member
Hi,
I want to programmatically set the arguments for running a python script
and I want to run it programmatically.

My goal is to do programmatically what you would normally do by hand with
right mousekey>run as...>run configuration
and setting the arguments.

Unfortunately, my search did not help me on this (or I was lacking the
right keywords).
Please help me find out wether it is possible at all and if so, how to
accomplish it.
Thanks for your consideration.
Re: set run configuration programmtical, launch programmatical [message #335731 is a reply to message #335724] Fri, 24 April 2009 10:40 Go to previous messageGo to next message
Prakash G.R. is currently offline Prakash G.R.Friend
Messages: 621
Registered: July 2009
Senior Member
Jens B. wrote:
> Hi,
> I want to programmatically set the arguments for running a python script
> and I want to run it programmatically.
> My goal is to do programmatically what you would normally do by hand with
> right mousekey>run as...>run configuration and setting the arguments.

See:
http://www.eclipse.org/articles/Article-Launch-Framework/lau nch.html
http://www.eclipse.org/articles/Article-Java-launch/launchin g-java.html

- Prakash

---
http://blog.eclipse-tips.com
Re: set run configuration programmtical, launch programmatical [message #335758 is a reply to message #335731] Tue, 28 April 2009 09:43 Go to previous message
Jens B. is currently offline Jens B.Friend
Messages: 2
Registered: July 2009
Junior Member
Thank you, Prakash, your hint was very helpful.

To sum it up for others with the same problem:
Read the article, substitute

ILaunchConfigurationType type =
manager.getLaunchConfigurationType(ID_JAVA_APPLICATION);

for

ILaunchConfigurationType type =
manager.getLaunchConfigurationType(org.python.pydev.debug.co re.Constants.ID_PYTHON_REGULAR_LAUNCH_CONFIGURATION_TYPE);

and if eclipse complains about unset attributes, create a configuration
manually and search all attributes of the workingCopy programmatical,
where you should get the String constants for the desired attributes.

Bewa
Previous Topic:p2 metadata generator doesn't complete
Next Topic:Missing Required Bundle org.eclipse.wst.common.modulecore_0.0.0
Goto Forum:
  


Current Time: Fri Dec 27 02:18:25 GMT 2024

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

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

Back to the top