Indentation

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Indentation

Andre Louw-2
Hi all,

I need some help. We all have our specific idiosyncrasies, one of mine is
that I'm hooked on
my indentation and general appearance of my source files.
Unfortunately I'm running into trouble when checking in or out from
QuantLib's CVS.
Any file that I worked on that somebody else worked on as well I get
conflicts, 99% of the time because of
indentation. Unfortunately this works vice-versa as well.
I haven't really checked but I'm pretty sure there must be some automated
way of getting this to work.
IOW get a common .indent.pro on the CVS server, which all files are
converted to when checked in,
and a personal .indent.pro which is used when checking out.

Luigi,

I used the indent.pro file you sent me a while ago but I've noticed the
indent
option --braces-on-struct-decl-line tends to break c++ files!!!!

Any body out there with some experience in this line?

Andre
 
-------------------------------------------------------------------------
This e-mail is intended only for the use of the individual or entity named
above and may contain information that is confidential and privileged,
proprietary to the company and protected by law. If you are not the intended
recipient, you are hereby notified that any dissemination, distribution or
copying of this e-mail is strictly prohibited. Opinions, conclusions and
other information in this message that do not relate to the official
business of our company shall be understood as neither given nor endorsed by
it.


Reply | Threaded
Open this post in threaded view
|

Re: Indentation

Luigi Ballabio-4
At 6:58 PM +0200 4/29/02, Andre Louw wrote:
>I need some help. We all have our specific idiosyncrasies, one of mine is
>that I'm hooked on my indentation and general appearance of my source files.

It seems to be a widespread disease here :)

>Unfortunately I'm running into trouble when checking in or out from
>QuantLib's CVS.
>Any file that I worked on that somebody else worked on as well I get
>conflicts, 99% of the time because of
>indentation. Unfortunately this works vice-versa as well.
>I haven't really checked but I'm pretty sure there must be some automated
>way of getting this to work.
>IOW get a common .indent.pro on the CVS server, which all files are
>converted to when checked in,
>and a personal .indent.pro which is used when checking out.

Andre,
        I just checked a fe CVS resources on line. It is possible to
run a program upon commit and/or update: however, the programs are
run only after the cvs operation succesfully terminates---one can't
pipe the cvs incoming/outgoing data through them :(

>Luigi,
>
>I used the indent.pro file you sent me a while ago but I've noticed the
>indent
>option --braces-on-struct-decl-line tends to break c++ files!!!!

Ouch. This is a strange one: shuffling around whitespace shouldn't
break C++ code...  What exactly happens to the source?

        Luigi

--


Reply | Threaded
Open this post in threaded view
|

Re: Indentation

Ferdinando M. Ametrano-2
In reply to this post by Andre Louw-2
At 06:58 PM 4/29/2002 +0200, Andre Louw wrote:
>I'm running into trouble when checking in or out from
>QuantLib's CVS.
>Any file that I worked on that somebody else worked on as well I get
>conflicts, 99% of the time because of
>indentation.
It's been probably my fault. Next time I will be more careful.

>I haven't really checked but I'm pretty sure there must be some automated
>way of getting this to work.
>IOW get a common .indent.pro on the CVS server, which all files are
>converted to when checked in,
>and a personal .indent.pro which is used when checking out.
To use 2 different .indent.pro on the CVS side and the developer side
wouldn't mark all files as modified?

This said if we settle on one .indent.pro and automate the CVS I would go
for it

ciao -- Nando