Hacker News new | past | comments | ask | show | jobs | submit login

"b-but the UNIX philosophy!"

The more time I spend with UNIX and hear the "UNIX philosophy" used in place of argument when someone doesn't like the feature set of some software, the more I realize that we need to move on from UNIX. We should take more ideas from things like Emacs and the Lisp machines when designing our software, and less from UNIX.




You might enjoy The UNIX-HATERS Handbook [1], published in 1994. It offers a still-relevant critical perspective on the UNIX paradigm, birthed in a context that had been exposed to alternatives.

[1] http://web.mit.edu/~simsong/www/ugh.pdf


I'm a big fan of the UNIX-HATERS Handbook. :)

(For some additional perspective, I don't really hate UNIX, I still recall how much of a breath of fresh air it was coming from Windows, but I think it, much like the X server, is really showing its age.)


Emacs has very few self-contained mega packages; in its own way, Emacs software is built by chaining together smaller packages. Many packages are little more than extensions to other packages.


But their interop is better. Besides Emacs packages having much greater "contact surface" (packages can augment other packages, if needed), the biggest problem with UNIX philosophy is using unstructured text as exchange medium. It leads to huge waste and proliferation of bugs, as each tool or script you use has to have its own custom (and bug-ridden) parser, and outputs its own unstructured and usually undocumented data format. This is one of those moments the history of computing took a huge step backwards. All that recent push for passing JSON around instead of plaintext? That's just rediscovering what we've lost when UNIX came along.


Filenames may contain newlines. JSON strings may contain newlines.

The modular aspects of the UNIX philosophy are pretty cool; the data interchange format (un-typed \n-delimited strings) is irrational (and

dangerous).

JSON w/ a JSONLD @context and XSD type URIs may also contain newlines (which should be escaped)

Note that, with OSX bash, tab \t must be specified as $'\t'.

And, sometimes, it's \r\n instead of just \n (which is extra-format metadata).

And then Unicode. Oh yeah, unicodë.


You don't have to use $'', you can also use literal tabs (ctrl-v to insert literals). The main difference between macOS and Linux that people notice is that macOS sed doesn't itself interpret \t (so you have to use literal tabs or $'' there).

\r\n is Windows, not Unix.

What about Unicode? (Btw, UTF-8 was created by unixers Rob Pike and Ken Thompson https://www.cl.cam.ac.uk/~mgk25/ucs/utf-8-history.txt )


With Ctrl-V <tab>, it's not possible to determine whether it's spaces or tabs (without cursoring over the /s|/t)

When you're parsing a text file, or streaming lines of text delimited with /n, how do downstream programs know whether it's ASCII or unicode?


Working with a LISP brings me far more enjoyment than piping plain-old-text. :)

OTOH, I'll take SExps over JSON, thanks.


Unix Philosophy makes thing overly complex and Unix doesn't follow Unix Philosophy. All these little programs have over lapping features.

http://www.johndcook.com/blog/2010/06/30/where-the-unix-phil...

man page for ls and see if they built a ton onto the little program and not just write new programs.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: