Earlier quoted context omitted.
> And forbidding it makes a one-keystroke action a two or four one. You can’t be serious
Not everyone wants a bloated and buggy IDE to write their code for them.
Why are we templating YAML? (2019)
221–230 of 667 posts
Re: Why are we templating YAML? (2019)
#222I agree that YAML templating is kind of insane, but I will never understand why we don't stop using fake languages and simply use a real language. If you need complex logic, use a programming language and generate the YAML/JSON/whatever with it. There you go. Fixed it for you. Ruby, Python, or any other language really (I only favor scripting ones because they're generally easier to run), will give you all of that wi…
Re: Why are we templating YAML? (2019)
#223I agree that YAML templating is kind of insane, but I will never understand why we don't stop using fake languages and simply use a real language. If you need complex logic, use a programming language and generate the YAML/JSON/whatever with it. There you go. Fixed it for you. Ruby, Python, or any other language really (I only favor scripting ones because they're generally easier to run), will give you all of that wi…
Re: Why are we templating YAML? (2019)
#224Re: Why are we templating YAML? (2019)
#225To me YAML seems like the CoffeeScript of JSON, and unlike CoffeeScript I don’t understand why people are still using it. I guess XML and JSON are too verbose. But YAML is so far in the opposite direction, we get the same surprise conversions we’ve had in Excel ( https://ruudvanasseldonk.com/2023/01/11/the-yaml-document-fr... ). Why is “on” a boolean literal (of course so are “true”, “false”, as well as “yes”, “no”,…
Note: YAML is a superset of JSON, which means that any YAML reader can read JSON.
Re: Why are we templating YAML? (2019)
#226I agree that YAML templating is kind of insane, but I will never understand why we don't stop using fake languages and simply use a real language. If you need complex logic, use a programming language and generate the YAML/JSON/whatever with it. There you go. Fixed it for you. Ruby, Python, or any other language really (I only favor scripting ones because they're generally easier to run), will give you all of that wi…
Agreed, and I almost feel silly for pointing this out, but for writing JSON (JavaScript Object Notation), I'd recommend using JavaScript...
Sticking to a scripting language with a strong standard library is way better.
Any unix system can get Ruby/Python and read/write YAML/JSON immediately without caring too much about versions.
Of course in today's upside down world most developers seem to only know JS, so it would at least be "familiar". Still a bad choice in my view.
The way this industry is going, give it a few years and we'll have React-Kubernetes for generating templates. And I wish I was joking.
Re: Why are we templating YAML? (2019)
#227Earlier quoted context omitted.
The biggest issue I have with Yaml is that they forbid tabs. Their argument is that tabs are shown differently in every editor which is actually something I like. When you're looking for something deeply nested you can reduce the tab distance a bit, when that's not needed you can increase it to improve visibility of nesting levels. And forbidding it makes a one-keystroke action a two or four one. I really don't under…
> And forbidding it makes a one-keystroke action a two or four one. You can’t be serious
Re: Why are we templating YAML? (2019)
#228Worse yet, in some places (CI/CD) YAML becomes nearly a programming language. A very verbose, unintuitive, badly specified and vendor-specific one as well.
This criticism doesn't pass the sniff test though: your average Haskeller loves to extoll the virtues of using Haskell to implement a DSL for some system which is ultimately just doing the same thing in practice (because they're still not going to write documentation for it, but hey, how hard can it be to figure out it's just...) YAML becomes a programming language because vendors need a DSL for their system, and the…
Re: Why are we templating YAML? (2019)
#229Earlier quoted context omitted.
The problem isn't with the small configuration files, those are just argv put into a file. Here's an experiment actually worth doing: ask ten people to write a ini file for configuring between 3 and 6 servers where some properties are the same for several servers.
It'd generate same set of problems in INI, YAML, TOML, XML, JSON, BICF (bayindirh's imaginary configuration format). Because these are not related to how you write the file, but how your software operates in your mind.
If we accept the assertion that the complexity of a configuration file for the stated scenario is constant across all configuration formats, we will next be asserting that there's no difference in complexity between solutions in x86 assembly and LISP.
Re: Why are we templating YAML? (2019)
#230Most devops folks are former sysadmins with no developer experience.
The tools needed to be able to be picked up quickly without too much pain.
This is why our devops tooling in popular usage is not as robust as developer tools.
Know your audience.