cookstyle icon indicating copy to clipboard operation
cookstyle copied to clipboard

Cookstyle configuration "streams"

Open dafyddcrosby opened this issue 1 year ago • 1 comments

Motivation

As a Chef power user,
I want to use the latest and greatest Cops,
so that I can see and fix problems early, and get the most out of Cookstyle.

As an off-and-on Chef user,
I want to be able to occasionally update the set of Cops,
so that I can incrementally improve my codebase when I have time.

As a CI owner/someone who can't change code often,
I want to see a CI that doesn't go red without notice,
so that I can do other things besides chasing style points.

Specification

The current thinking is something like TargetChefVersion in .rubocop.yml. We can specify a CookstyleCopStream which has values of stable (the current set, which almost never changes save for bug fixes), dates for yearly snapshots (eg YYYYMMDD) so that new Cops can be ratcheted in easily, and latest (what it says on the tin).

Downstream Impact

  • Existing customers, generally speaking, don't need to change. Stable is the default.
  • Folks who are comfortable with Cookstyle/Chef/Ruby can do new cop development without the worry of breaking.

dafyddcrosby avatar Dec 14 '23 19:12 dafyddcrosby

After stepping away from the keyboard, I think we'll want to strike stable and instead have the first snapshot be the default. We don't want to imply that it's any more stable than the other snapshots or latest, just that it's a fixed point in time, showing how far removed that first snapshot is from the other snapshots/latest as a point of reference.

dafyddcrosby avatar Dec 14 '23 19:12 dafyddcrosby