Re: .cvsignore file

Lists: pgsql-patches
From: Rod Taylor <rbt(at)rbt(dot)ca>
To: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: .cvsignore file
Date: 2002-10-11 01:43:40
Message-ID: 1034300621.297.6.camel@jester
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

Add ignore file to doc/src/sgml

Makes cvs diff go by quicker on a compiled tree as it doesn't ask the
repo about the new .html files.
--
Rod Taylor

Attachment Content-Type Size
.cvsignore text/plain 61 bytes

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Rod Taylor <rbt(at)rbt(dot)ca>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: .cvsignore file
Date: 2002-10-11 04:22:03
Message-ID: 2246.1034310123@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

Rod Taylor <rbt(at)rbt(dot)ca> writes:
> Add ignore file to doc/src/sgml

> Makes cvs diff go by quicker on a compiled tree as it doesn't ask the
> repo about the new .html files.

This strikes me as a bad idea. We use .cvsignore only for files that
should survive "make distclean", which the built docs files surely
shouldn't.

regards, tom lane


From: Rod Taylor <rbt(at)rbt(dot)ca>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: .cvsignore file
Date: 2002-10-11 11:56:14
Message-ID: 1034337374.297.17.camel@jester
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

On Fri, 2002-10-11 at 00:22, Tom Lane wrote:
> Rod Taylor <rbt(at)rbt(dot)ca> writes:
> > Add ignore file to doc/src/sgml
>
> > Makes cvs diff go by quicker on a compiled tree as it doesn't ask the
> > repo about the new .html files.
>
> This strikes me as a bad idea. We use .cvsignore only for files that
> should survive "make distclean", which the built docs files surely
> shouldn't.

Why not ignore the set of compiled files as well? I realize its a much
larger list, but seems a fairly common thing to do. It does prevent the
overhead with CVS server in the event someone does check against a
compiled tree.

Doesn't really hurt anything either way.

--
Rod Taylor


From: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
To: Rod Taylor <rbt(at)rbt(dot)ca>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: .cvsignore file
Date: 2002-10-11 15:50:02
Message-ID: 20021011155002.GA4177@dcc.uchile.cl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

On Fri, Oct 11, 2002 at 07:56:14AM -0400, Rod Taylor wrote:

> Why not ignore the set of compiled files as well? I realize its a much
> larger list, but seems a fairly common thing to do. It does prevent the
> overhead with CVS server in the event someone does check against a
> compiled tree.

Yeah, it would also help clean the output of cvs diff, automatically
ignoring files that aren't important. I always have to clean it up...

--
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"No reniegues de lo que alguna vez creíste"


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Rod Taylor <rbt(at)rbt(dot)ca>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: .cvsignore file
Date: 2002-10-12 04:56:46
Message-ID: 9519.1034398606@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

Rod Taylor <rbt(at)rbt(dot)ca> writes:
> On Fri, 2002-10-11 at 00:22, Tom Lane wrote:
>> This strikes me as a bad idea. We use .cvsignore only for files that
>> should survive "make distclean", which the built docs files surely
>> shouldn't.

> Why not ignore the set of compiled files as well? I realize its a much
> larger list, but seems a fairly common thing to do.

Well, exactly, it's a much larger list, and hence a much larger
maintenance effort. If it were near-zero cost to maintain then
I'd be okay with it ... but right now, it seems most reasonable
to expect people to do "make distclean" before they try a "cvs diff".

In practice, you have to be mighty savvy to do "cvs update"s without a
"make distclean" beforehand --- I don't ever risk it myself; the extra
machine cycles for a full rebuild are way cheaper than my time to debug
an incomplete rebuild. So I have little concern for the "cvs diff"
case.

regards, tom lane


From: Rod Taylor <rbt(at)rbt(dot)ca>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: .cvsignore file
Date: 2002-10-12 14:57:39
Message-ID: 1034434660.6674.110.camel@jester
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

On Sat, 2002-10-12 at 00:56, Tom Lane wrote:
> Rod Taylor <rbt(at)rbt(dot)ca> writes:
> > On Fri, 2002-10-11 at 00:22, Tom Lane wrote:
> >> This strikes me as a bad idea. We use .cvsignore only for files that
> >> should survive "make distclean", which the built docs files surely
> >> shouldn't.
>
> > Why not ignore the set of compiled files as well? I realize its a much
> > larger list, but seems a fairly common thing to do.
>
> Well, exactly, it's a much larger list, and hence a much larger
> maintenance effort. If it were near-zero cost to maintain then
> I'd be okay with it ... but right now, it seems most reasonable
> to expect people to do "make distclean" before they try a "cvs diff".
>
> In practice, you have to be mighty savvy to do "cvs update"s without a
> "make distclean" beforehand --- I don't ever risk it myself; the extra
> machine cycles for a full rebuild are way cheaper than my time to debug
> an incomplete rebuild. So I have little concern for the "cvs diff"
> case.

Yes, before updating you definitely want to do that, but it usually
takes me a few tries to undo parts where I've gone wrong. So diffs
regularly happen along the way.

Anyway, don't maintain by hand

The below should make .cvsignore entries for most files. I can test it,
and clean it up to be put under src/tools if wanted if this method is
ok. No, it's not perfect but running it shortly before or after a
pgindent run would cover 90% of the cases.

#!/bin/sh
# Run from PGSQL directory
./configure
find * -name .cvsignore -delete
make all check
cd doc/src && make all && cd ..
cvs diff 2>&1 | perl -e '
while ($line = <STDIN>)
{
chomp($line);
if ($line =~ /^\?\s.*\/.*/)
{
$line =~ s/^\?\s(.*\/)([^\/]+)$/echo \"$2\" >> $1.cvsignore\n/;
print $line;
} elsif ($line =~ /^\?\s/)
{
$line =~ s/^\?\s([^\/]+)$/echo \"$1\" >> .cvsignore\n/;
print $line;
}
}' | sh

--
Rod Taylor


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Rod Taylor <rbt(at)rbt(dot)ca>
Cc: PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: .cvsignore file
Date: 2002-10-12 15:46:58
Message-ID: 12315.1034437618@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

Rod Taylor <rbt(at)rbt(dot)ca> writes:
> Anyway, don't maintain by hand

> find * -name .cvsignore -delete

That's a rather draconian implementation of the "don't maintain by hand"
notion. I don't think it will coexist well with having .cvsignore files
in CVS ...

regards, tom lane