You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hop.apache.org by ha...@gmail.com on 2024/04/19 08:55:27 UTC
[DISCUSS] include spotless to our builds
Hi Hoppers,
I am a bit in a spring cleanup mode, now that we have checkstyle included (with 1 rule but we'll get to more later) I would like to discuss adding spotless to our builds.
Spotless allows us to pick a formatting style and automatically apply it when building the code. We can also add a check to our PR's to see if the code has been formatted properly.
In the past we had decided to use the google formatter to format our code, and I think it is still mostly correct but as we were not enforcing it some drift has happened over the years.
Different code styles by editors and personal preference makes PR review and validation harder as all code could get marked as changed due to formatting reasons. This could allow not so good actors to sneak in code changes we would not want.
Let me know what you think, and if we agree I'll do the work.
Cheers,
Hans
Re: [DISCUSS] include spotless to our builds
Posted by Bart Maertens <ba...@know.bi>.
+1. the more consistency, the better
On Fri, Apr 19, 2024 at 10:56 AM <ha...@gmail.com> wrote:
> Hi Hoppers,
>
> I am a bit in a spring cleanup mode, now that we have checkstyle included
> (with 1 rule but we'll get to more later) I would like to discuss adding
> spotless to our builds.
> Spotless allows us to pick a formatting style and automatically apply it
> when building the code. We can also add a check to our PR's to see if the
> code has been formatted properly.
>
> In the past we had decided to use the google formatter to format our code,
> and I think it is still mostly correct but as we were not enforcing it some
> drift has happened over the years.
> Different code styles by editors and personal preference makes PR review
> and validation harder as all code could get marked as changed due to
> formatting reasons. This could allow not so good actors to sneak in code
> changes we would not want.
>
> Let me know what you think, and if we agree I'll do the work.
>
> Cheers,
> Hans
>
Re: [DISCUSS] include spotless to our builds
Posted by "Matt Casters (i-Bridge)" <ma...@ibridge.be>.
The only advice I could offer is to document what is expected of
contributors and why.
Op di 23 apr 2024 20:50 schreef <ha...@gmail.com>:
> Hi all,
>
> As there are no objections I am moving forward with this.
> If we encounter issues we can remove it again. It will as Francois pointed
> out create a first commit with a lot of changes.
>
> Kr,
> Hans
> On 19 Apr 2024 at 18:01 +0200, Francois Papon <
> francois.papon@openobject.fr>, wrote:
> > Hi,
> >
> > No objection from my side.
> >
> > Just a warning about activating spotless because we will have a lot of
> > git diff at the first activation...
> >
> > I had some bad feedback when using spotless in some projects.
> >
> > Regards,
> >
> > François
> >
> > On 19/04/2024 10:55, hans.van.akelyen@gmail.com wrote:
> > > Hi Hoppers,
> > >
> > > I am a bit in a spring cleanup mode, now that we have checkstyle
> included (with 1 rule but we'll get to more later) I would like to discuss
> adding spotless to our builds.
> > > Spotless allows us to pick a formatting style and automatically apply
> it when building the code. We can also add a check to our PR's to see if
> the code has been formatted properly.
> > >
> > > In the past we had decided to use the google formatter to format our
> code, and I think it is still mostly correct but as we were not enforcing
> it some drift has happened over the years.
> > > Different code styles by editors and personal preference makes PR
> review and validation harder as all code could get marked as changed due to
> formatting reasons. This could allow not so good actors to sneak in code
> changes we would not want.
> > >
> > > Let me know what you think, and if we agree I'll do the work.
> > >
> > > Cheers,
> > > Hans
> > >
>
Re: [DISCUSS] include spotless to our builds
Posted by ha...@gmail.com.
Hi all,
As there are no objections I am moving forward with this.
If we encounter issues we can remove it again. It will as Francois pointed out create a first commit with a lot of changes.
Kr,
Hans
On 19 Apr 2024 at 18:01 +0200, Francois Papon <fr...@openobject.fr>, wrote:
> Hi,
>
> No objection from my side.
>
> Just a warning about activating spotless because we will have a lot of
> git diff at the first activation...
>
> I had some bad feedback when using spotless in some projects.
>
> Regards,
>
> François
>
> On 19/04/2024 10:55, hans.van.akelyen@gmail.com wrote:
> > Hi Hoppers,
> >
> > I am a bit in a spring cleanup mode, now that we have checkstyle included (with 1 rule but we'll get to more later) I would like to discuss adding spotless to our builds.
> > Spotless allows us to pick a formatting style and automatically apply it when building the code. We can also add a check to our PR's to see if the code has been formatted properly.
> >
> > In the past we had decided to use the google formatter to format our code, and I think it is still mostly correct but as we were not enforcing it some drift has happened over the years.
> > Different code styles by editors and personal preference makes PR review and validation harder as all code could get marked as changed due to formatting reasons. This could allow not so good actors to sneak in code changes we would not want.
> >
> > Let me know what you think, and if we agree I'll do the work.
> >
> > Cheers,
> > Hans
> >
Re: [DISCUSS] include spotless to our builds
Posted by Francois Papon <fr...@openobject.fr>.
Hi,
No objection from my side.
Just a warning about activating spotless because we will have a lot of
git diff at the first activation...
I had some bad feedback when using spotless in some projects.
Regards,
François
On 19/04/2024 10:55, hans.van.akelyen@gmail.com wrote:
> Hi Hoppers,
>
> I am a bit in a spring cleanup mode, now that we have checkstyle included (with 1 rule but we'll get to more later) I would like to discuss adding spotless to our builds.
> Spotless allows us to pick a formatting style and automatically apply it when building the code. We can also add a check to our PR's to see if the code has been formatted properly.
>
> In the past we had decided to use the google formatter to format our code, and I think it is still mostly correct but as we were not enforcing it some drift has happened over the years.
> Different code styles by editors and personal preference makes PR review and validation harder as all code could get marked as changed due to formatting reasons. This could allow not so good actors to sneak in code changes we would not want.
>
> Let me know what you think, and if we agree I'll do the work.
>
> Cheers,
> Hans
>