git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Honoring a checked out gitattributes file
@ 2009-01-28 15:25 Kristian Amlie
  2009-01-28 16:44 ` Michael J Gruber
  2009-01-28 17:55 ` Honoring a checked out gitattributes file Jeff King
  0 siblings, 2 replies; 22+ messages in thread
From: Kristian Amlie @ 2009-01-28 15:25 UTC (permalink / raw)
  To: git

Hi!

We currently use msysGit in our company test farm to checkout the latest
development branch and do autotests. However, we have one problem:
Certain files require UNIX line endings, even though this is a Windows
system. For this we use .gitattributes.

However, if the .gitattributes file is also checked in to the branch, it
will not always be honored. I browsed the code a bit, and it seems to
happen whenever there is an existing .gitattributes file, but the
checkout adds new files to it. These new files will not get the correct
line endings (although I'm not sure if it happens *every* time, it could
depend on the order they are checked out).

I think this should be fairly straightforward to fix, by ensuring that
if there is a file called .gitattributes in the index of the current
directory, check it out first, before all the other files that may be
affected by it. I can produce a patch and testcase for it, but I wanted
to hear the opinions of some developers in case there is an obvious flaw
in my solution.

What do you think?

--
Kristian Amlie

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

end of thread, other threads:[~2009-03-20  9:34 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-28 15:25 Honoring a checked out gitattributes file Kristian Amlie
2009-01-28 16:44 ` Michael J Gruber
2009-01-28 17:25   ` Kristian Amlie
2009-01-30 13:00     ` Kristian Amlie
2009-01-30 13:00       ` [PATCH] Add a test for checking whether gitattributes is honored by checkout Kristian Amlie
2009-03-12  9:36       ` Honoring a checked out gitattributes file Kristian Amlie
2009-03-12  9:36         ` [PATCH 1/2] Add a test for checking whether gitattributes is honored by checkout Kristian Amlie
2009-03-12  9:36           ` [PATCH 2/2] Make Git respect changes to .gitattributes during checkout Kristian Amlie
2009-03-12  9:59             ` Johannes Sixt
2009-03-12 10:23               ` Kristian Amlie
2009-03-13 13:24               ` Honoring a checked out gitattributes file Kristian Amlie
2009-03-13 13:24                 ` [PATCH 1/2] Add a test for checking whether gitattributes is honored by checkout Kristian Amlie
2009-03-13 13:24                   ` [PATCH 2/2] Make Git respect changes to .gitattributes during checkout Kristian Amlie
2009-03-14  4:17                     ` Junio C Hamano
2009-03-19 15:42                       ` Kristian Amlie
2009-03-19 21:06                         ` Junio C Hamano
2009-03-20  8:11                           ` Kristian Amlie
2009-03-20  9:32                             ` [PATCH] Add a test for checking whether gitattributes is honored by checkout Kristian Amlie
2009-03-14  4:36                   ` [PATCH 1/2] " Junio C Hamano
2009-03-12  9:47           ` Matthieu Moy
2009-03-12  9:53             ` Kristian Amlie
2009-01-28 17:55 ` Honoring a checked out gitattributes file Jeff King

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 NNTP newsgroup(s).