Our great sponsors
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
-
Pulumi
Pulumi - Infrastructure as Code in any programming language. Build infrastructure intuitively on any cloud using familiar languages 🚀
-
oil
Oils is our upgrade path from bash to a better language and runtime. It's also for Python and JavaScript users who avoid shell!
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
You can have trailing commas just fine: https://github.com/dhall-lang/dhall-lang/pull/956
However, `dhall format` is _very_ opinionated, and will remove it.
- should I come up with my own declarative, configuration-like DSL? It would probably end up similar to Dhall, but this means I can do whatever I want - I can make it as ergonomic and custom as I want to (which I guess is both good and bad :D!). It might also allow for nicer interop with Javascript and other languages.
In this case, we went for the last option, mostly because we felt the most important thing is ergonomics and interop, but well, I am still curious how would other directions play out. Plus at the end we didn't yet get to the point where language is more expressive than JSON (code example: https://github.com/wasp-lang/wasp).
Maybe I am just missing a better design process, but it seems to me that with language that it is hard to say if it is good or not until you try using it.
Depending on the use-case, I think you may be right. Especially if you can use a language that the team understands and has tooling for and you don't take in outside configuration.
Pulumi is an interesting tool in this direction. Rather than write in something like teraform, you just use your programming language of choice. Pulumi is just a library you use.
https://www.pulumi.com/
A few months ago I explored using Dhall and Jsonnet to re-write an Ansible playbook [0,1]. I wanted to like Dhall, but found the type system got in the way more than it helped, while Jsonnet was very productive and a huge improvement over YAML.
[0] https://www.kmr.me/posts/dhall_jsonnet
[1] https://github.com/retzkek/ansible-dhall-jsonnet
I highly recommend https://github.com/koalaman/shellcheck It's a wonderful piece of software to help and guide users writing shell scripts. Hook it up to your editor/IDE and all those arcane caveats will be things of the past.
What is funny is that a shell script does a pretty good job at giving you a nice, programmable way to invoke software. But, that is too complicated :-)
Ha, I agree, although I also think shell is a bit impoverished. It works but there are valid reasons people don't use it.
I hope to add the "missing declarative part" to shell in https://www.oilshell.org :
https://lobste.rs/s/6oxpe3/s_lot_yaml#c_mje209
Prediction: we'll see a lot more shell in YAML in the coming years, with the same examples shown in the original article (Github Actions, didn't know about Helm Charts) IMO we should get rid of the YAML.
https://lobste.rs/s/v4crap/crustaceans_2021_will_be_year_tec...
There is. It's called HOCON and I'm surprised it's not mentioned yet:
https://github.com/lightbend/config/blob/master/HOCON.md
HOCON is the "human optimised config object notation" and is a superset of JSON. All valid JSON is valid HOCON but then it goes and adds lots of other features specifically designed for writing usable config files.
Related posts
- INTERCAL, YAML, And Other Horrible Programming Languages
- Unmasking Ghost Parameters, or How to Save Time and Money
- Shift from ENV Files to Configuration-as-Code
- GitHub - Configu: Open-source project that puts an end to your configuration Chaos
- Configu - Open-source project that puts an end to your configuration Chaos