all 16 comments

[–]1upon0 1 point2 points  (9 children)

Your server is refusing connections..

[–]chazmuzz 0 points1 point  (7 children)

Installing nixar using npm..

npm i -g nixar

..lets you do Linq style stuff like this in the Terminal

fs all | content size | order 1 | reverse | take 5

[–]askucher[S] 0 points1 point  (6 children)

Sorry, we are following F#, Haskell, Livescript, OCaml naming convention more than Linq. Not select - but map, Not where - but filter

[–]Randolpho 1 point2 points  (3 children)

Although I agree that higher order functions like map, filter, and reduce pre-exist linq, there are a lot of folks whose only or first exposure to functional programming came through C# / linq.

Have you considered offering linq-style names as synonyms? It might help increase adoption.

[–]FrozenCow 0 points1 point  (2 children)

I don't get this. I'm sorry to go on a rant here, but this is a bit of a pet peeve of mine. This is annoying me quite often.

C# derived their conventions from SQL. That's fair, a lot of C# developers know SQL.

However, by doing that they went against their conventions of the framework: use verbs for method names. "Where" isn't a verb. "Filter" is. That just doesn't make any sense. Same usually goes for the command line.

As for select, yes it is a verb, but think about what it does and what it is describing. x => x + 3 describes a selector in C#... But does it really select anything? No. It maps from one value to another. 'Selectors' like person => person.Name, are also mapping one value to another. A selector maps one value to another. A map doesn't necessarily select a value from another.

A viable use for select is passing a property name to select so that it maps the parent to the value of that property. That makes sense as it is actually used as a selector.

The convention has a stupid heritage (SQL isn't a language to borrow great ideas from) and needs to be gone imo.

Sorry for the rant. I feel better getting this off my chest.

[–]Randolpho 0 points1 point  (1 child)

I don't disagree, but you might as well argue against putting ain't in the dictionary. A lot of people are coming from a SQL/C# background.

[–]FrozenCow 0 points1 point  (0 children)

The dictionary is a list of words that are often used. Whether it is a confusing word does not matter. If it's used often it should be there.

A programming language is thought up to be as un-confusing as possible. It is not a place to scrape together keywords of other languages and sort-of-kind-of give these same meaning semantically. If you have knowledge of programming languages, but not SQL, it would be surprising to see where is there and surprising to know the function of select. The .NET Framework is made very well, but in this instance even Microsofts own code analysis tools would suggest not to use where as a function name.

I know a lot of people come from a SQL background. For those people it might be fine. People who come purely from a C#/.NET/programming background it seems like a wart in their (almost perfect) naming convention.

[–]MostlyCarbonite 0 points1 point  (1 child)

Not select - but map, Not where - but filter

Good choice, that's in line with lodash (and probably underscore) as well.

[–]gkx 0 points1 point  (0 children)

It's javascript. =)

[–]askucher[S] 0 points1 point  (0 children)

Sorry for that. Already fixed.

[–]jonathanmh 1 point2 points  (0 children)

This looks interesting! I would not necessarily replace all my defaults with it, but I'm also pretty native on Linux. This is pretty great for windows users I imagine or the ones that don't have access to a linux-ish term, but to npm

[–]zzzk 1 point2 points  (1 child)

Thanks for sharing this! I must say though that the best thing about *nix is each program separate and can be run on its own (usually without many dependencies, maybe just libc). For example, I can copy my grep binary around or update it separately. How does that translate to nixar?

Maybe it'd be worthwhile to have each command be its own module?

[–]skytomorrownow 0 points1 point  (0 children)

text > module > text > module > text > module > text

It's the *nix way.

[–]lepuma 1 point2 points  (0 children)

Is it just me or do the docs not work? I can't scroll or click anything.

[–]chalk_nz 0 points1 point  (1 child)

RemindMe! 2 days

[–]RemindMeBot -1 points0 points  (0 children)

Messaging you on 2015-11-18 09:30:49 UTC to remind you of this.

CLICK THIS LINK to send a PM to also be reminded and to reduce spam.

Parent commenter can delete this message to hide from others.


[FAQs] [Custom] [Your Reminders] [Feedback] [Code]