git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [gambit-list] Separating generated files? (Re: Mercurial -> git)

From
CJChristian Jaeger <christian@pflanze.mine.nu>
Date
Oct 15, 2008, 17:28 UTC
Message-ID
<48F62834.9080102@pflanze.mine.nu>
In-Reply-To
<48F61D77.3080100@drmicha.warpmail.net>
Michael J Gruber wrote:
Show 5 quoted lines
> I wonder whether a clever use of "excludes" and GIT_DIR would allow
> tracking the different filesets in the same dir, but using different
> repos. I'm just afraid it's a fragile setup, in the sense that it relies
> on config stuff which is not tracked (and thus not reproduced
> automatically on clone).

I expect that using a superproject repository to tie together the two repositories is good and necessary because it is the link that allows to specify which commit in the repo of generated files belongs together with a commit in the repo of source files. So just using two separate repositories without making them submodules of a superproject does not seem to be a good idea to me.

Once there is a superproject repository, one could also commit config files of the submodules into it (I'm not sure what that will buy though--.gitignore is outside and can committed anyway, at least as long as not both repositories are overlaid as you suggest).

You're probably right that strictly speaking, there is no need to move generated files out into a separate directory tree; but I think doing the move would be worthwhile since it takes away one level of complexity (you can then access the build/.git repository without the need of setting GIT_DIR), and because it may be a good idea anyway (for example it will be easier to grep the sources without getting hits from the generated files). [Also, the exclude patterns wouldn't be easy, as we couldn't really just exclude all *.c files from the view of the source repository, since there are also some hand-crafted ones; the excludes would need full paths which would have to be kept up to date manually, unless we wanted to live with the fact that newly created manual .c files would be added using "git add -f".]

Christian.
Previous: Michael J GruberNext: Christian Jaeger
Message 4 of 9 in “Re: Separating generated files? (Re: Mercurial -> git)”
  1. Nguyen Thai Ngoc DuyOct 15, 2008
  2. Matthieu MoyOct 15, 2008
  3. Michael J GruberOct 15, 2008
  4. Christian JaegerOct 15, 2008
  5. Christian JaegerOct 16, 2008
  6. Santi BéjarOct 16, 2008
  7. Christian JaegerOct 16, 2008
  8. Santi BéjarOct 16, 2008
  9. Christian JaegerOct 15, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.