Relative Paths in creating Projects [message #193452] |
Thu, 12 February 2004 12:49  |
Eclipse User |
|
|
|
Originally posted by: rmccammon.mccammoninc.com
Greetings All,
I want to make the directory of a project relative to a base directory
so several people using different OS’s can share the project. I defined
a path variable, WS_DIR, to mean “P:\Projects\Delego” in Preferences >
Workbench > Linked Resources with the intention of changing the value to
“/opt/Projects” when the project moves to a UNIX environment.
When creating the project, I use WS_DIR as the path variable in the
directory field. All seems well at this point. If I type simply WS_DI,
Eclipse complains about an unknown path variable with the message: ”
WS_DI is not a valid location. The location is relative to undefined
workspace path variable "WS_DI".” Since the workspace is a subdirectory
of the base directory defined by WS_DIR, then the message
“P:/Projects/Delego and p:/Projects/Delego/workspace overlap.” is
displayed by Eclipse after the entire variable is typed and until more
characters are entered. The entire entry is “WS_DIR\Java\CH”
After saving the project, I look at the properties of the project and
under the Info page, the location of the project is listed as
“C:\eclipse\WS_DIR\Java\CH”. No substitution for WS_DIR actually took
place and instead the installation path for eclipse is added.
I tried various combinations to get the path variable to expand such as
${WS_DIR:\Java\CH}
${WS_DIR\Java\CH}
$WS_DIR\Java\CH
WS_DIR:\Java\CH
Always Eclipse wants to add the installation path and does not expand
the path variable. I even tried substituting “/” for “\”.
Any direction someone can provide me to get the path variable to stick
in the directory name is appreciated and expand as needed is appreciated.
Best regards,
Richard
|
|
|
|
|
|
Re: Relative Paths in creating Projects [message #200367 is a reply to message #193452] |
Mon, 23 February 2004 19:03  |
Eclipse User |
|
|
|
Originally posted by: John_Arthorne.oti.com_
Path variables were only designed to work for linked resources. It turns
out they worked for project locations at one time, but this wasn't
intentional. See the following feature request:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=49600
--
Richard wrote:
> Greetings All,
>
> I want to make the directory of a project relative to a base directory
> so several people using different OS’s can share the project. I defined
> a path variable, WS_DIR, to mean “P:\Projects\Delego” in Preferences >
> Workbench > Linked Resources with the intention of changing the value to
> “/opt/Projects” when the project moves to a UNIX environment.
>
> When creating the project, I use WS_DIR as the path variable in the
> directory field. All seems well at this point. If I type simply WS_DI,
> Eclipse complains about an unknown path variable with the message: ”
> WS_DI is not a valid location. The location is relative to undefined
> workspace path variable "WS_DI".” Since the workspace is a subdirectory
> of the base directory defined by WS_DIR, then the message
> “P:/Projects/Delego and p:/Projects/Delego/workspace overlap.” is
> displayed by Eclipse after the entire variable is typed and until more
> characters are entered. The entire entry is “WS_DIR\Java\CH”
>
> After saving the project, I look at the properties of the project and
> under the Info page, the location of the project is listed as
> “C:\eclipse\WS_DIR\Java\CH”. No substitution for WS_DIR actually took
> place and instead the installation path for eclipse is added.
>
> I tried various combinations to get the path variable to expand such as
>
> ${WS_DIR:\Java\CH}
> ${WS_DIR\Java\CH}
> $WS_DIR\Java\CH
> WS_DIR:\Java\CH
>
> Always Eclipse wants to add the installation path and does not expand
> the path variable. I even tried substituting “/” for “\”.
>
> Any direction someone can provide me to get the path variable to stick
> in the directory name is appreciated and expand as needed is appreciated.
>
> Best regards,
>
> Richard
>
|
|
|
Powered by
FUDForum. Page generated in 0.08253 seconds