Earlier quoted context omitted.
PowerShell was started by a single person, Microsoft's Jeffrey Snover. As the project progressed other designers came on board but Snover remained (and remains) as Chief Architect. The design-by-committee allegation isn't being fair to him. Part of why PowerShell may seem not quite Unix-like, is Snover didn't just look at Unix as an influence. Snover's professional background included experience with IBM OS/400's CL…
Once you start using PWSH, the design decisions are so obvious and make so much sense, that it is obvious Jeffrey Snover did have vast experience with variety of shells and languages. The idea to tie it with .NET and COM+ on windows is the best a shell has ever done, though someone noted in another thread that it is an old idea from XEROX mainframes (not sure what the name was). if you want to imagine this in terms o…
GitHub – nushell/nushell: A new type of shell
231–240 of 411 posts
Re: GitHub – nushell/nushell: A new type of shell
#232The title is somewhat misleading and makes it seem like this is a GitHub company initiative rather than a project just hosted on GitHub. I've not seen this title format on HN before. Could it be changed?
I think the "nushell/nushell" part makes it clear which repo it is talking about.
Re: GitHub – nushell/nushell: A new type of shell
#233Earlier quoted context omitted.
powershell for unix is ... powershell: https://docs.microsoft.com/en-us/powershell/scripting/instal...
Am I missing something cool by not looking into PowerShell for Linux? Anyone using it could chime in and share how it improves their workflow? What kind of tools does it bring to the table?
It's not a good interactive shell environment though. The commands are way too verbose and the syntax feels clunky for keying in.
Re: GitHub – nushell/nushell: A new type of shell
#234Earlier quoted context omitted.
I tried fish for a while. The differing syntax between fish and bash for fundamental things mean I was running all my scripts through bash anyway, and if I wanted to share them/use them elsewhere in the company it had to be bash, so I swapped back to bash.
That's not entirely weird to me. For the longest time bash was in various states of disrepair on different Unixes. I could make it segfault pretty easily. I wrote scripts that had to run across Linux, BSD, HP-UX, Solaris, and AIX at the time. So we relied on a ksh88 implementation on each. Whether it was AT&T, mksh, or pdksh, it was fine. Couldn't rely on 93isms, but basically anything POSIX was cool. I used ksh93 in…
Re: GitHub – nushell/nushell: A new type of shell
#235Re: GitHub – nushell/nushell: A new type of shell
#236Earlier quoted context omitted.
Am I missing something cool by not looking into PowerShell for Linux? Anyone using it could chime in and share how it improves their workflow? What kind of tools does it bring to the table?
Disclaimer: I use PowerShell on Windows, I've never tried it on Linux, but I don't see why its advantages wouldn't transfer. That being said, I think it's main advantages are: - Typed object streams, which gives you stuff like autocomplete, IDE support, and generally there's no need to muck about with sed/awk/xargs - Very fast, it's absolutely fine to read a file line by line, and parse it in a script, whereas doing…
Or it follows the opposite mentality and the sell comes with batteries included?
I'm thinking of some arbitrary example, like downloading a JSON and parsing it to obtain some nested sub-property. In Bash world you would use the shell to execute at least something like `wget` to do the download part, and then run `jq` to parse the JSON and select the desired property. Both of `wget` and `jq` are independent programs, installed separately, with their own input & output channels, that you combine together by using the shell itself.
How would this work with PowerShell? (feel free to use some other example that might be better suited)
Re: GitHub – nushell/nushell: A new type of shell
#237Thinking this is so cool! I was wondering if seriously buying into an alternate shell like this would be worth it in the long run. Would really love to read from people who use(d) an alternative shell, both success and failure stories. I cannot shake from my head the idea that buying into a non-standard shell will only work for personal projects in one's own workstation, but it won't fly too far for company work beca…
Is it so bad? I run arch at home, I would never do that for a production server. I use rust at home, but it's unlikely to get introduced at my work any time soon. I use elm for solo projects, and I've never once convinced my managers to even try it (and believe me, I tried).
Context switching is pretty normal, I wouldn't let that get in the way of trying something new and interesting. Personally I find elv.sh the sanest scripting language I've tried so far, and I wouldn't trade it back in for bash, even if I'm still forced to use it at work.
Re: GitHub – nushell/nushell: A new type of shell
#238Earlier quoted context omitted.
Can you write a bash one-liner that gets the free memory of your system? Is the awk blackmagic better than selecting an item of an object? Of course new things will be harder to write but it’s a people problem not something inherent with PS.
is the writing part really what we should focus on in scripting though? i personally would've put much more weight into the ease of reading and understanding the code. personally, i think that PS just came too late, so most people (me included) are too used to the way the unix shell works/feels. It would have to be just straight up better in all regards to displace it, but its more like a different flavor entirely. I…
Re: GitHub – nushell/nushell: A new type of shell
#239I played with it recently. The interactive part is limited at the moment, but I really like the idea of having operations like sorting and filtering separate from the tools which produce the data. Having these things consistent and available everywhere is a huge cognitive win. I can finally sort and filter `ls` output without having to read the man page. :) "Querying" data feels a lot like SQL in that respect.
Were you not able to before? ls | grep foo | sort is hardly something people normally read the man page for.
Re: GitHub – nushell/nushell: A new type of shell
#240Thinking this is so cool! I was wondering if seriously buying into an alternate shell like this would be worth it in the long run. Would really love to read from people who use(d) an alternative shell, both success and failure stories. I cannot shake from my head the idea that buying into a non-standard shell will only work for personal projects in one's own workstation, but it won't fly too far for company work beca…
Tangential, but:
- "Node" isn't a language, it's a JS runtime
- There's no such thing as an "interpreted language", whether something is interpreted or not is a property of the execution environment, not of the language itself
- The commonly-used runtimes for JS at least are JIT compilers, not "interpreters", and this can be true for some Python/Ruby runtimes too