3 ms·
This is funny to me, because git config is one of the few bastions of sane configuration. The language is not turing complete, there's no real schema, it's not
by xyzzy_plugh 5y ago
This is funny to me, because git config is one of the few bastions of sane configuration. The language is not turing complete, there's no real schema, it's not quite TOML, the tooling to read/write values is sublime. Your custom tools can just start using it however you want. Config is all local, nothing is inherited or executed from remote sources.
It's just key=value. Whether value is a URL, a number, a shell command -- totally up for interpretation.
Sure, not having a schema has it's downsides but by god, I love git config.
- amelius 5y ago> This is funny to me, because git config is one of the few bastions of sane configuration. Just give it a few years, and we'll have statements like "IncludeIfFileExistsAndSatfisfiesConditionXandY" and you'll be begging for a Turing complete language ;) Also, what happens if your configuration file contains a typo, say "eemail" instead of "email"? My guess is that Git will simply ignore it, whereas in a programming language, you would call "set_email(...)" and you would get an error if the function didn't exist. Now that's what I call sanity.
- OJFord 5y ago> what happens if your configuration file contains a typo, say "eemail" instead of "email"? My guess is that Git will simply ignore Sort of - you will set the config option "eemail", but yes, of course anything looking for "email" configuration will ignore it.