Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » adding an existing file to the project
adding an existing file to the project [message #215401] Sat, 03 May 2008 08:20 Go to next message
Eclipse UserFriend
Originally posted by: vitaly.panor.zoran.com

Is there a way of adding an existing file (not a directory) to the
project, without copying it to the project directory? Something similar to
"add existing item" in Visual Studio.

Thanks
Re: adding an existing file to the project [message #215494 is a reply to message #215401] Mon, 05 May 2008 18:45 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: newsgroups.snipah.com

Yes.

Context Menu
New -> File -> Advanced -> Link to file in file system

Enrico

Vitaly Panor wrote:
> Is there a way of adding an existing file (not a directory) to the
> project, without copying it to the project directory? Something similar to
> "add existing item" in Visual Studio.
>
> Thanks
>
Re: adding an existing file to the project [message #215700 is a reply to message #215494] Wed, 07 May 2008 17:34 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: gbr.majentis.com

Enrico Ehrich wrote:

> Yes.

> Context Menu
> New -> File -> Advanced -> Link to file in file system

> Enrico

> Vitaly Panor wrote:
>> Is there a way of adding an existing file (not a directory) to the
>> project, without copying it to the project directory? Something similar to
>> "add existing item" in Visual Studio.
>>
>> Thanks
>>

I'm sure if my first post went through, so sorry for the double post if it
did.

New -> File -> Advanced -> Link inserts absolute paths. I need relative
paths, since each developer can put their source tree wherever they want.

Is there a way to use relative paths?
Re: adding an existing file to the project [message #215707 is a reply to message #215494] Wed, 07 May 2008 18:03 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: gbr.majentis.com

Enrico Ehrich wrote:

> Yes.

> Context Menu
> New -> File -> Advanced -> Link to file in file system

> Enrico

> Vitaly Panor wrote:
>> Is there a way of adding an existing file (not a directory) to the
>> project, without copying it to the project directory? Something similar to
>> "add existing item" in Visual Studio.
>>
>> Thanks
>>

To answer my own question...

Environment variables didn't seem to work. But when you link to a file in
the filesystem, it has its own variables. I set that up, and each dev
sets up the same variable name to point to the proper path on their
system, and it all works.

Kinda backwards, I think. Using files in alternate directories is so
common, that relative positioning should just work without doing the
backflips.
Re: adding an existing file to the project [message #215915 is a reply to message #215494] Sun, 11 May 2008 03:27 Go to previous message
Eclipse UserFriend
Originally posted by: vitaly.panor.zoran.com

Hi Enrico,

Thanks a lot!
Previous Topic:Content assist with smart pointers
Next Topic:JavaDoc Plugin for CDT
Goto Forum:
  


Current Time: Sun Jun 08 13:45:07 EDT 2025

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

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

Back to the top