Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Reformatting of code

I realize it is easier to have standard way of working.  But in the end that reduces once person's efforts by pushing them on to others.

I'm willing to compromise with proposal #2 which is to reformat in a separate commit.  It will take an extra 2 minutes to do, but will save much more for the person coming after.

And BTW, turning off the auto-reformat on save, is a lot easier than spending an hour merging code.  You could even write an EASE script to add a button to toggle the reformatter (if that doesn't exist already).


From: cdt-dev-bounces@xxxxxxxxxxx [cdt-dev-bounces@xxxxxxxxxxx] on behalf of Doug Schaefer [cdtdoug@xxxxxxxxx]
Sent: March 15, 2016 11:13 AM
To: CDT General developers list.
Subject: Re: [cdt-dev] Reformatting of code

I work on several projects. CDT is only one of them. I'd prefer not to have per project requirements for this. It's too hard to keep straight.

I also have format on save turned on to make sure I format all the code I touch. I recommend everyone do the same and use the default Java formatter. Then this will be less of an issue over time as we get all or code formatted the same.

Doug.

On Tue, Mar 15, 2016 at 10:13 AM, Marc Khouzam <marc.khouzam@xxxxxxxxxxxx> wrote:
Hello,

I would like to suggest a procedure when reformatting entire java files for CDT.

Personally, I use the git history very much, so reformatting has an impact on that.
Merging local changes can also become quite painful.
I recently spent over an hour merging a local change into a file that had been
fully reformatted. This does not feel like time well-spent.  And it's not enjoyable either.

I suggest that either:
1- we simply avoid reformatting
or
2- if justified, any file reformatting be done in its own commit

Thoughts?

Marc



_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/cdt-dev


Back to the top