Live data from Hacker News

The Rule of Silence (2006)

linfo.org

301–310 of 318 posts

Re: The Rule of Silence (2006)

#301
post #100

Earlier quoted context omitted.

Maybe many tiny sqlite databases? Then you would not need to to centralize your data in a single database, but still do queries across different config files.

SQLite is a huge win. All the power of SQL, and you don't have to introduce system-wide and non-local dependencies.

How is this a win? Instead of opening a text file we have to write update statements to change any setting. Sql is itself a verbose language that should have been discarded in the 80's.

Re: The Rule of Silence (2006)

#302
post #130

Earlier quoted context omitted.

It's not like unstructured piped text is the only possible way to work. It's widely used precisely because it's so expedient. If you use structured data, then every program in the sequence has to understand the structure. If you just smash everything flat into a stream of text, you can then massage it into whatever form you need. It's not always the best way to approach a problem, but it's not meant to be. It's duct…

If you use structured data in a standard format, you can have a single system-wide implementation of a parser and then have each program process the data it needs, already structured in a semantically-meaningful way. In current, unstructured text reality, each program has to have its own (usually buggy, half-assed) shotgun parser, and it has to introduce semantic meaning back to the data all by itself. And then it de…

But if your data is structured in a semantically meaningful way, then your receiving program needs to understand those semantics. Maybe you could introduce new command line tools to refactor streams of data so as to adapt one program to another, but I can't see it being simpler and quicker (in terms of piping input from one place to another) than the current approach.

I do like the idea of a standard parser to avoid the ad-hoc implementation of parsers into everything.

Your last comment gives a hint at the real problem, which is people using command line hackery in 'permanent' solutions. It's duct tape. You don't build important system components out of duct tape. Well, you shouldn't, anyway.

Re: The Rule of Silence (2006)

#303
post #62

I always liked how MacOS loads silently without annoying the user even when it does some "hard" stuff like fsck. Generally I think engineers need to fight the temptation to show off the importance and complexity of their software by spitting out all the unnecessary details and logs.

Don't all of the "user firendly" linux distros do this too?

Re: The Rule of Silence (2006)

#304
post #116

Earlier quoted context omitted.

Have you ever tried to talk to a person who gives absolutely no nonverbal cues as to whether or not they're listening to you? It's infuriating. Acks are important.

Yes I have. It's very common in some Eastern European countries, where the words stand on their own without embellishment. Jokes come with no intonation-based warnings. Similarily, listening is presumed and doesn't come with colorful Southern European–style cues. It's not infuriating, it's just different.

What's infuriating is when seven times out of ten, you eventually say "hey are you listening?" and they respond that of course they're listening, whyever wouldn't you think so? And the other three times out of ten they're actually not listening and they haven't heard a word you've said for the past few minutes, and you have to either repeat yourself or just stop trying to talk to the person.

Re: The Rule of Silence (2006)

#305

Earlier quoted context omitted.

Yeah, wow, all I have to do is write a bunch of regular expressions tailored to the unique output of this command instead of passing in a list of property names. It's so easy.

To add to that: a list of property names you don't even have to exactly know beforehand, since the shell can easily deliver you the exact data structure and metadata of any object (cmdlets, parameters, results,...) usable on the shell. I find the idea baffling that basically having to have the whole syntax tree memorized instead of the shell providing it for me is somehow less of a "waste of cognitive energy".

I really think people are mistaking "I'm not familiar with it" with "it's bad and poorly designed" because they've forgotten what it was like to first use the Unix command line.

Re: The Rule of Silence (2006)

#306
post #87

Earlier quoted context omitted.

Surely you can reconcile structured representations and something like the Unix command line. Imagine if the default wasn't bash, but something like Ruby + pipes (or some other terse language). What is the argument for shell scripts not working on typed objects? How much time has been lost, how many bugs have been created because every single interaction between shell scripts has to include its own parser. How many v…

>What is the argument for shell scripts not working on typed objects? Typed objects can make it harder to pipe commands together. How do you grep a tree when tree is an actual data structure and grep expects a list of items as input? You would need to have converters. Either specific converter between tree and list, or a generic one: tree->text->list. >Something Windows does get right is the clipboard. It useful, but…

grepping a tree would not be hard. You simply go down to the leaves and "grep" on the properties themselves. Inversely, structured data lets you easily get to a property.

For example, if you grep the output ls -l for a file named "1", you'll also get files with 1 in their timestamp. In text land, you have to edit the ls command to get simpler output. In structured land, you could edit your filter: ls -l | grep name~=1

You could imagine various structured data filter tools that could be built that wouldn't require modifying the input.

Though in this example, you can easily use awk to select the column, wouldn't it be nice to not have to worry about things like escape characters when parsing text?

Re: The Rule of Silence (2006)

#307
post #282

Earlier quoted context omitted.

Options to select output? Sounds like advice from the Rule of Silence. But. - People above were just complaining about having to use sed to tweak output. I don't see why they would prefer a built-in filter to an external one. The external filter is far more flexible, and if that isn't enough, you can replace it. - I'm generally not a fan of applications that tailor their output to what they think the human wants. Unl…

Yeah, wow, all I have to do is write a bunch of regular expressions tailored to the unique output of this command instead of passing in a list of property names. It's so easy.

[deleted]

Re: The Rule of Silence (2006)

#308
post #197
post #74

To play devil's advocate, part of the reason things like The Rule of Silence are talked about is because of the messy unix philosophy of treating everything like plain text. If structured data was embraced we would have developed appropriate tooling to interact with it in the way that we prefer. This runs very deep in unix and a lot of people are too "brainwashed" to think of other ways. Instead they develop other ex…

> ... the messy unix philosophy of treating everything like plain text. If structured data ... You are forgetting a crucial point: plain text is very well defined. Actually, it was already defined when the first Unix tools were being written. Using plain text means that you can use grep to search the logs of your program, even if your program was written yesterday and grep was written 40 years ago . Structured data?…

Clearly, you want to avoid the overloading caused by implementing a half baked version of Common LISP into every utility. Just use s-expressions.

Everyone can just boot into emacs :P.

Re: The Rule of Silence (2006)

#309
post #175

Earlier quoted context omitted.

JSON and XML are both horrible in their own ways, especially for use as configuration languages.

True, but my point is that the alternatives being proposed are vaporware. JSON works now. IMHO JSON is the least shitty of the shitty solutions that exist.

I guess my point is that if JSON is the least shitty alternative then I can't really agree that Unix-type environments would be better off using it for everything, because JSON is a pain in the ass to type and edit with a regular text editor... the same with XML... and the same with S-expressions... YAML is a monster, CSV isn't really structured, and so on...

Basically there is no universal structural language that's ergonomic and nice for all uses, so it makes sense that the Unix hackers of yore preferred to create tiny custom languages for everything. It's also because "worse is better".

https://www.jwz.org/doc/worse-is-better.html

Re: The Rule of Silence (2006)

#310
post #133

Earlier quoted context omitted.

What database has? To clarify: The registry is a database for OS or application stuff (caches, settings, etc.). It's not meant to be user-editable and outside arcane trouble-shooting stuff you're unlikely to ever have to venture in there.

Oracle, for one, has had it for a long time. "Use the COMMENT statement to add a comment about a table, view, materialized view, or column into the data dictionary." https://docs.oracle.com/cd/B19306_01/server.102/b14200/state...

Also mssql, the extended property ms_description can be applied to objects and columns and appears in SSMS as comments.
Post reply on HN