git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* gitattributes
@ 2007-04-24 11:36 Matthias Kestenholz
  2007-04-24 16:18 ` gitattributes Alex Riesen
  2007-04-24 17:15 ` gitattributes Junio C Hamano
  0 siblings, 2 replies; 5+ messages in thread
From: Matthias Kestenholz @ 2007-04-24 11:36 UTC (permalink / raw
  To: git

The .gitattributes system together with input/output filters has already
proven exceptionally useful for me. I've got some co-workers which
do not seem to care about CRLF line endings or whitespace damage.

core.autocrlf = input

and

[filter "whitespace"]
  clean = stripspace
  smudge = cat

and

*.php  filter=whitespace
*.tpl  filter=whitespace

saves me minutes every day when I review changes made by others,
because otherwise the diffs are getting illegible (Sometimes, the whole
file is shown twice only because the line-ending changed)

It would be really great if these features were included in the next
release.


Thanks,
Matthias

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

* Re: gitattributes
  2007-04-24 11:36 gitattributes Matthias Kestenholz
@ 2007-04-24 16:18 ` Alex Riesen
  2007-04-24 21:40   ` gitattributes Junio C Hamano
  2007-04-24 17:15 ` gitattributes Junio C Hamano
  1 sibling, 1 reply; 5+ messages in thread
From: Alex Riesen @ 2007-04-24 16:18 UTC (permalink / raw
  To: Matthias Kestenholz; +Cc: git

On 4/24/07, Matthias Kestenholz <lists@spinlock.ch> wrote:
> The .gitattributes system together with input/output filters has already
> proven exceptionally useful for me. I've got some co-workers which
> do not seem to care about CRLF line endings or whitespace damage.
>
> core.autocrlf = input
>
> and
>
> [filter "whitespace"]
>   clean = stripspace
>   smudge = cat
>

Why didn't --ignore-space-at-eol, -b and -w work for you?

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

* Re: gitattributes
  2007-04-24 11:36 gitattributes Matthias Kestenholz
  2007-04-24 16:18 ` gitattributes Alex Riesen
@ 2007-04-24 17:15 ` Junio C Hamano
  1 sibling, 0 replies; 5+ messages in thread
From: Junio C Hamano @ 2007-04-24 17:15 UTC (permalink / raw
  To: Matthias Kestenholz; +Cc: git

"Matthias Kestenholz" <lists@spinlock.ch> writes:

> The .gitattributes system together with input/output filters has already
> proven exceptionally useful for me. I've got some co-workers which
> do not seem to care about CRLF line endings or whitespace damage.
>
> core.autocrlf = input
>
> and
>
> [filter "whitespace"]
>  clean = stripspace
>  smudge = cat

You shouldn't need to say "smudge = cat"; if it does not work
without that line you found a bug, so please report.

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

* Re: gitattributes
  2007-04-24 16:18 ` gitattributes Alex Riesen
@ 2007-04-24 21:40   ` Junio C Hamano
  2007-04-24 22:06     ` gitattributes Matthias Kestenholz
  0 siblings, 1 reply; 5+ messages in thread
From: Junio C Hamano @ 2007-04-24 21:40 UTC (permalink / raw
  To: Alex Riesen; +Cc: Matthias Kestenholz, git

"Alex Riesen" <raa.lkml@gmail.com> writes:

> On 4/24/07, Matthias Kestenholz <lists@spinlock.ch> wrote:
>> The .gitattributes system together with input/output filters has already
>> proven exceptionally useful for me. I've got some co-workers which
>> do not seem to care about CRLF line endings or whitespace damage.
>>
>> core.autocrlf = input
>>
>> and
>>
>> [filter "whitespace"]
>>   clean = stripspace
>>   smudge = cat
>>
>
> Why didn't --ignore-space-at-eol, -b and -w work for you?

It should.  What Matthias would want more is probably to have
others to have the "clean" side of the filter in their working
repository.

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

* Re: gitattributes
  2007-04-24 21:40   ` gitattributes Junio C Hamano
@ 2007-04-24 22:06     ` Matthias Kestenholz
  0 siblings, 0 replies; 5+ messages in thread
From: Matthias Kestenholz @ 2007-04-24 22:06 UTC (permalink / raw
  To: Junio C Hamano; +Cc: Alex Riesen, git

2007/4/24, Junio C Hamano <junkio@cox.net>:
> "Alex Riesen" <raa.lkml@gmail.com> writes:
>
> > On 4/24/07, Matthias Kestenholz <lists@spinlock.ch> wrote:
> >> The .gitattributes system together with input/output filters has already
> >> proven exceptionally useful for me. I've got some co-workers which
> >> do not seem to care about CRLF line endings or whitespace damage.
> >>
> >> core.autocrlf = input
> >>
> >> and
> >>
> >> [filter "whitespace"]
> >>   clean = stripspace
> >>   smudge = cat
> >>
> >
> > Why didn't --ignore-space-at-eol, -b and -w work for you?
>
> It should.  What Matthias would want more is probably to have
> others to have the "clean" side of the filter in their working
> repository.

Yes, that's the reason. Furthermore, I like the approach of the filter
better than adding command line arguments (which I and others will
always forget on the first try)

I've just copy-pasted the smudge filter from an example I saw on
the list. I'll retest the filter setup tomorrow without "smudge = cat"
and look for problems.

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

end of thread, other threads:[~2007-04-24 22:06 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-04-24 11:36 gitattributes Matthias Kestenholz
2007-04-24 16:18 ` gitattributes Alex Riesen
2007-04-24 21:40   ` gitattributes Junio C Hamano
2007-04-24 22:06     ` gitattributes Matthias Kestenholz
2007-04-24 17:15 ` gitattributes Junio C Hamano

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).