git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* How does git deal with hard links in source code?
@ 2010-08-23  8:33 Seth Kriticos
  2010-08-23  9:00 ` Jakub Narebski
  0 siblings, 1 reply; 2+ messages in thread
From: Seth Kriticos @ 2010-08-23  8:33 UTC (permalink / raw)
  To: git

Hi list,

I've got a question my google-fu and the docs were not able
to answer:

Is there a way to preserve the hard links that are within
a git repository checkout (the stuff that is tracked by the
git repository)?

The use-case I have is the following: I want to have two
different template directories for stuff in the tracked
sources: a base one and some extended ones. I want to have
the stuff from the base one hard-linked to the extended one,
so changes in the base one change all the other depending
templates too.

Now for testing I committed and pushed an instance of this
and then cloned the repository, and it ate my hard links
(checked out two separate copies of the files).

Is there a way to convince git not to eat my hard links
without some complicated scripting magic and checkout hooks?

~ Seth Kriticos

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: How does git deal with hard links in source code?
  2010-08-23  8:33 How does git deal with hard links in source code? Seth Kriticos
@ 2010-08-23  9:00 ` Jakub Narebski
  0 siblings, 0 replies; 2+ messages in thread
From: Jakub Narebski @ 2010-08-23  9:00 UTC (permalink / raw)
  To: Seth Kriticos; +Cc: git

Seth Kriticos <seth.kriticos@googlemail.com> writes:

> I've got a question my google-fu and the docs were not able
> to answer:
> 
> Is there a way to preserve the hard links that are within
> a git repository checkout (the stuff that is tracked by the
> git repository)?

No, there isn't, and there shouldn't.  Not all filesystems support
hardlinks.
 
> The use-case I have is the following: I want to have two
> different template directories for stuff in the tracked
> sources: a base one and some extended ones. I want to have
> the stuff from the base one hard-linked to the extended one,
> so changes in the base one change all the other depending
> templates too.
> 
> Now for testing I committed and pushed an instance of this
> and then cloned the repository, and it ate my hard links
> (checked out two separate copies of the files).
> 
> Is there a way to convince git not to eat my hard links
> without some complicated scripting magic and checkout hooks?

Make hardlinks on deploy.

-- 
Jakub Narebski
Poland
ShadeHawk on #git

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-08-23  9:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-08-23  8:33 How does git deal with hard links in source code? Seth Kriticos
2010-08-23  9:00 ` Jakub Narebski

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).