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

Re: sub-directory repo technique

From
Avery Pennarun <apenwarr@gmail.com>
Date
Jun 16, 2009, 16:50 UTC
Message-ID
<32541b130906160950s75f4aa11h59ad2de7d2bcd40c@mail.gmail.com>
In-Reply-To
<9586f3420906120507o194fc459l5fbdcd14a7095ae8@mail.gmail.com>
On Fri, Jun 12, 2009 at 8:07 AM, Allan Kelly<allankelly@gmail.com> wrote:
> (I need the top-level .gitignore to contain a line '.gitignore' to
> avoid reporting the "sub-repo" .gitignore as untracked - which is
> correct but not of interest. It appears that git automatically ignores
> the .git dir for the westbarnsgala.info repo created below)

It's not really "ignoring" the .git dir. It's treating the entire subtree that contains the .git dir as a submodule. See 'man git-submodule'. Git submodules may actually resolve your problem in a more straightforward way than what you're doing.

You might also be interested in my git-subtree tool: http://github.com/apenwarr/git-subtree

Have fun,
Avery
Previous: Allan Kelly
Message 2 of 2 in “sub-directory repo technique”
  1. Allan KellyJun 12, 2009
  2. Avery PennarunJun 16, 2009

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.