[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Using Common files across multiple projects
From: |
Pierre Asselin |
Subject: |
Re: Using Common files across multiple projects |
Date: |
20 Nov 2001 15:24:17 -0600 |
address@hidden (Thomas Frasher) writes:
>I'm trying to change the repository that we are using here.
>There are several projects that use some of the same files, headers and .cpp
>files.
>[...]
>I'm confused reading the documentation, it seems the ampersan commands are
>what is needed here, but I haven't been able to figure out how they work.
Amperstand modules are exactly what you need.
>Ideally I would like the checkout to get the files automatically, whether
>they are in a different repository (i.e. a different module) or whether they
>are local.
You can only mix files at the granularity of a directory. You *can not*
have one directory populated by files from two different modules.
It's generally not too hard to structure your sources that way but if
you can't, you have to give up on CVS.
The simplest example would have a modules file looking like this:
common path/to/common/files
project_1 path/to/top/of/project_1 &common
project_2 path/to/top/of/project_2 &common
...
When you check out project_1, you get:
project_1/
file
file
...
common/
common-file
common-file
...
> Also I need to put them back to the "home" repository when the
> changes are committed (all this without the need to commit me at
> the end of it).
Check. When you commit project_1, the common/ subtree is committed
with it and people working on project_2 have to update. Be careful that
changes to project_1/common not break project_2 !
--
Pierre Asselin
Westminster, Colorado
-----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
-----== Over 80,000 Newsgroups - 16 Different Servers! =-----