by zokier · 11y ago · 0 comments
"Under the hood Windows, unlike Mac OS, is DOS- rather than unix-based"
Last DOS based Windows was released like 15 years ago. At that time Macs had their own weird OS too.
"A general point about unix commands: they're often robust."
Unix commands, robust? You gotta be kidding me, they are great for quick ad-hoc hacks, but robust they are not. Just as an example here is how the common task of handling can fail: http://www.dwheeler.com/essays/filenames-in-shell.html
"For example, with ls you can use an arbitrary number of arguments and it obeys the regular expression (more about these later) convention that an asterisk matches anything"
How this is an example of robustness? Besides globbing is not regular expressions. In regexp you'd use .* to match anything, not a bare *
> However, a file in Microsoft Word's proprietary and unknown formatting is utterly unusable.
While I'm no fan of Word, it is very much arguable that Word file format not anymore proprietary or unknown.
> I used to use Smultron until I found, unforgivably, that the spacing of documents when you looked at them in the editor and on the terminal was different.
Let me guess, tab width difference? Yeah, that is how tabs work and not really a fault in the editor.
For the first time ever I had to deal with xargs and find together last week. Bear in mind I've been using Unix for about 20 years now. Telling one command to null delimit stuff and another to parse the nulls is horrible. Especially seeing as this only came about because one directory happened to have a lot of files in it and the 11 year old script just went snap. I'm perhaps lucky I've never encountered this.
The author needs to take a look at powershell. Surprisingly I wrote a job site scraper in it in about 10 lines of code. Html parsing, data access etc are right there at your finger tips. That and it'll quite happily move 23TiB/1780000 files in a single incantation without wincing once.
Colour me impressed (as an old Unix die hard)
I'm really curious about this. Do you have a very specific workflow that gets around that need or an alternative that would replace find + xargs? Is your job pretty niche? It just seems like I _need_ it a few times a week minimum, and I'm not really sure what would replace it off the top of my head.
I do agree on powershell being quite slick. Sometimes finding what I want is a process, but so was unix in the beginning.
But more seriously, it only looks like the Unix shell. Operators like '|' can have very different semantics, especially when passing objects around and whatnot.
http://www.gnu.org/software/parallel/man.html#DIFFERENCES-BE...
One thing some people might not know is that DOS itself is slightly Unix-based; e.g. the hierarchical file system (directories within directories), command-line piping (though limited in features as compared to Unix), even the MORE command (ditto), etc. This is as opposed to, and an improvement over, CP/M, for example (a popular predecessor OS to DOS, on mainly 8-bit micros), which didn't have a hierarchical file system (IIRC - I've actually used both, CP/M lightly, DOS a lot, ages ago).
http://en.wikipedia.org/wiki/MS-DOS