How to influence current directory when starting Eclipse 3.0.1 (Windows) [message #49273] |
Fri, 08 April 2005 14:56 |
Eclipse User |
|
|
|
Originally posted by: Martin.Purkert.bawag.com
Hi there!
We have the following constellation.
Unfortunately, we have two projects in Eclipse. One containing Java-Code
and one containing lots of resources as xml-files etc.
Due to bad design (not from me ;-) ) the java-code reads the resource
files with relative paths from the current dir. Under Eclipse 2.1 we met
this requirement by starting Eclipse from a Link setting the current dir
to the resource project directory.
This has no effect with Eclipse 3.0.1 the current dir is changed to the
actual project dir. So in our case when executing, the java code does not
find it's resource files.
I want to ask if there is some possibility to override that behaviour and
to set the current dir in Eclipse 3.0.1.
thx in advance
regards
Martin Purkert
|
|
|
Re: How to influence current directory when starting Eclipse 3.0.1 (Windows) [message #49419 is a reply to message #49273] |
Fri, 08 April 2005 16:53 |
Eclipse User |
|
|
|
Originally posted by: wegener.cboenospam.com
Martin Purkert wrote:
> Hi there!
> We have the following constellation.
> Unfortunately, we have two projects in Eclipse. One containing Java-Code
> and one containing lots of resources as xml-files etc.
> Due to bad design (not from me ;-) ) the java-code reads the resource
> files with relative paths from the current dir. Under Eclipse 2.1 we met
> this requirement by starting Eclipse from a Link setting the current dir
> to the resource project directory.
> This has no effect with Eclipse 3.0.1 the current dir is changed to the
> actual project dir. So in our case when executing, the java code does not
> find it's resource files.
> I want to ask if there is some possibility to override that behaviour and
> to set the current dir in Eclipse 3.0.1.
> thx in advance
> regards
> Martin Purkert
It sounds like you are developing java applications and not plugins for
eclipse. In this case, you can set the working directory in the launch
configuration. It is at the bottom of the Arguments tab.
|
|
|
Re: How to influence current directory when starting Eclipse 3.0.1 (Windows) [message #50409 is a reply to message #49419] |
Mon, 11 April 2005 06:58 |
Eclipse User |
|
|
|
Originally posted by: Martin.Purkert.bawag.com
Thank you for the tip!
My situation is a little more tricky. I should explain it more detailed.
All in all we have 3 Eclipse projects involved.
The first one (lets call it the "GUI-Project") contains mainly Swing
Dialogs using the Visual Editor (VEP).
On that dialogs are lots of custom controls which sources are located in
the second project (the "Architecture" project).
And the architecture needs files from the third ("Resource") project.
So architecture code is not launched explicitly as Java Application (where
I could set the working dir as you mentioned) but implicitly when I open a
screen of the "GUI"-Project in the Visual Editor.
In production scenario all three projects are deployed in one dir so it
works there. It's only in development where I have to find a solution.
If nothing in that direction is possible, I think about adapting the
architecture code, so that it checks if running in development environment
and looks for a path in a System property or something set by Eclipse
start.
regards
Martin Purkert
|
|
|
Powered by
FUDForum. Page generated in 0.08927 seconds