DEFRA / software-development-standards

Standards and guidance relating to software development in Defra
https://defra.github.io/software-development-standards/
Other
45 stars 17 forks source link

Groovy code style standard #57

Closed johnwatson484 closed 2 years ago

johnwatson484 commented 4 years ago

Several pipelines in Defra use Jenkins with Groovy syntax. Like our other languages we should have a style guide that standardises on it's use.

Particularly as Groovy has several gotchas that if known may change how you would write code. For example the "private" (not private) keyword.

johnwatson484 commented 4 years ago

@bensagar-ea , on reflection, maybe referencing the Groovy style guide by Apache is sufficient. It is a bit vague, but I worry that if we're too prescriptive on how to write Groovy based on nothing but our preference, the standard might be too strict.

Maybe we should just say follow Apache as a baseline?

https://groovy-lang.org/style-guide.html