Open iay opened 7 months ago
Good plan. Mine can be all over the place, I try to make them consistent, but...
Is this the one: https://yamllint.readthedocs.io/en/stable/. I can brew install that.
That's the one. As well as Homebrew, it's also just a Python thing so it's easy to install for CI work.
It will pick up configuration files from the current directory if you name them correctly, so you can start easy (excluding some rules, files or even directories) and tighten up as you go. So it's possible to start using it without a lot of investment.
It's quite hard to keep consistent conventions across YAML files without a tool to help. I suggest we start using
yamllint
. This is configurable so the vast majority of things it currently flags (missing header line, long text lines) can be configured away to start with by adding a configuration file.With those ignored, there seem to be a fair number of a couple of different kinds of indentation issue (which is to be expected, and actually the thing I had noticed myself), some stuff about "truthy" values and, curiously, a couple of cases where it notices files with CRLF termination instead of LF.
As well as manual runs, we can consider adding it to the CI.
Longer term, we can consider making it stricter.