3 ms·
> You are literally one missing tab away from breaking your entire configuration file. In JSON, you’re one curly brace away from breaking your entire configura
by xigoi 5mo ago
> You are literally one missing tab away from breaking your entire configuration file.
In JSON, you’re one curly brace away from breaking your entire configuration file. How is that different?
- hexfran 5mo agoI guess the missing brace is a scope delimiter and easy to notice if missing, while the tab is an indentation marker and much harder to spot, and might get you into an invalid state but still parse correctly, just not doing what it was meant to do
- simoncion 5mo agoAdditionally, file segments [0] written with a grammar that uses scope-defining character pairs survive round trips through email, chat, the paste buffers of a series of less-than-maximally-careful coworkers, etc. etc. etc. much, much better than those written with a grammar that uses whitespace to define scope. <strike>Ask me how I know.</strike> [0] sections? snippets? fragments? Hopefully you get what I'm trying to say here.
- nalekberov 5mo agoJSON isn’t ideal either, however missing curly braces are much easier to fix than figuring out where you misaligned entries without going through entire config file.
- xigoi 5mo agoI’d just like to know what kind of workflow you have that causes indentation to randomly change in your files.
- simoncion 5mo agoDo you not use an editor that permits you perform at least one operation that would alter the indentation level of multiple lines all at once? Separate from that, have you never fat-fingered the tab, space, backspace or delete keys? Never deleted one too many whitespace tokens when cleaning up an inadvertent or misdirected paste? (If you've never done that, then kudos to you... but in two to six decades, it's certain to happen to you annoyingly often.)
- xigoi 5mo ago> Do you not use an editor that permits you perform at least one operation that would alter the indentation level of multiple lines all at once? Yes, but I don’t just randomly perform the operation when I don’t want to change the indentation. > Separate from that, have you never fat-fingered the tab, space, backspace or delete keys? When I’m in insert mode, I look at what I’m writing, so I immediately undo any such accidental edit. Outside insert mode, it’s hard to accidentally change indentation. > Never deleted one too many whitespace tokens when cleaning up an inadvertent or misdirected paste? I use indentation-preserving paste, so… no?
- simoncion 5mo agoAh. You're The One. Got it. Well, I'll likely be long dead once time's erosion of your body's self-repair machinery has destroyed your ability to be The One. Given that, please do accept this package containing my condolences for your loss. Time's insults are profoundly cruel and unjust.