|
|
|
|
|
Re: WTP and static resources in utility projects [message #232375 is a reply to message #232368] |
Thu, 11 June 2009 12:59 |
Eclipse User |
|
|
|
Originally posted by: Kevin.REMOVE.Dean.datadevelopment.com
Alex Tanaev wrote:
>Yes, I experimented with a link, and it seems to work. There is just a
>small annoying thing: I manage to make it work with linked resources and
>variables, but this requires an absolute path. It is OK, but may be there
>is a way to specify links not as 'relative to a path variable', but as
>'relative to this project'?
Sort of. When you go into the Java build path, select "Link Source..."
and then choose "Variables". From there, you can create a variable (e.g.
WSRoot) that refers to your workspace root. You can use this variable as
the basis for your linked source no matter where your workspace is
installed.
|
|
|
Re: WTP and static resources in utility projects [message #232409 is a reply to message #232375] |
Fri, 12 June 2009 07:01 |
Alex Tanaev Messages: 7 Registered: July 2009 |
Junior Member |
|
|
Kevin Dean wrote:
> Alex Tanaev wrote:
>>Yes, I experimented with a link, and it seems to work. There is just a
>>small annoying thing: I manage to make it work with linked resources and
>>variables, but this requires an absolute path. It is OK, but may be there
>>is a way to specify links not as 'relative to a path variable', but as
>>'relative to this project'?
> Sort of. When you go into the Java build path, select "Link Source..."
> and then choose "Variables". From there, you can create a variable (e.g.
> WSRoot) that refers to your workspace root. You can use this variable as
> the basis for your linked source no matter where your workspace is
> installed.
Well, this is exactly what I was doing.
My question was: is it possible to define a linked resource _without_
defining a variable with absolute path.
Look, .project has now something like
<linkedResources>
<link>
<name>linked_folder</name>
<type>2</type>
<locationURI>CURRENT_WA/UtilProject/sharedWebFiles</locationURI >
</link>
</linkedResources>
1. I was hoping there is some "predefined" variable referring to the
current workspace root. Apparently not, so I have to define CURRENT_WA as
a variable referring to my workspace root.
2. But maybe locationURI syntax has some other way to refer to the current
workspace root? After all, it has a special way to refer to variables, so
may be, just may be...
Alex
|
|
|
Re: WTP and static resources in utility projects [message #232455 is a reply to message #232409] |
Sun, 14 June 2009 10:30 |
Eclipse User |
|
|
|
Originally posted by: Kevin.REMOVE.Dean.datadevelopment.com
Alex Tanaev wrote:
>1. I was hoping there is some "predefined" variable referring to the
>current workspace root. Apparently not, so I have to define CURRENT_WA as
>a variable referring to my workspace root.
Unfortunately, no. However, the user variable is user-specific so anyone
working on the project that uses another directory structure just has to
set the user variable to point to their root.
>2. But maybe locationURI syntax has some other way to refer to the current
> workspace root? After all, it has a special way to refer to variables, so may be, just may be...
It would be nice. Directory management in Eclipse is all over the map;
there are some places where they work relative to the workspace root,
others where the workspace root isn't considered, and on and on.
|
|
|
|
Powered by
FUDForum. Page generated in 0.03548 seconds