News for hackers. Stuff that matters.
Re:Codecov breach impacts GoDaddy, Atlassian, P&G etc. by goatinaboat on Sunday April 18, 2021 @01:17PM (#26854328)
In my experience, relying on "prettifier" websites is directly a result of the lack of canonical, well-supported CLI tools for prettifying most programming and markup languages. It's such a weird glaring gap in dev tooling.

There's a CLI linter for pretty much every language I've used, but how would you prettify a valid YAML file? Any reformatting will change it semantically.

Re:Codecov breach impacts GoDaddy, Atlassian, P&G etc. by sundbry on Monday April 19, 2021 @01:13AM (#26859290)
You just parse and reserialize it. The trick is handling comments.
Re:Codecov breach impacts GoDaddy, Atlassian, P&G etc. by dathinab on Monday April 19, 2021 @04:24PM (#26867557)
Don't underestimate YAML and not fully compliant YAML parsers(1) and sterilizer's with everything but nice results.

(1): Which can be necessary to prevent accidental problems like NO defaulting to false not "NO" and similar. I personally strongly recommend against anything where string quotes are optional for human written/edited serialization formats (and comments are a must have).