from Hacker News

Ask HN: Is there a decent configuration format?

by xena on 4/27/25, 5:07 AM with 1 comments

Hey all,

I'm working on bot protection software and something I've run into is that YAML landlines can and will hit you at the worst times possible. Is there a configuration format that makes it easy to use for less technically apt people and lets you write regular expressions without having to double escape backslashes in strings? I also need it to have good support in Go, ideally with a way to get the same semantics as encoding/json.

Thanks in advance!

  • by rlupi on 4/27/25, 3:20 PM

    In TOML you can use triple-quoted strings to avoid double escaping backslashes.

    There is one example right at the bottom of https://toml.io/en/