Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Well the problem is that what should be the lingua-franca in a post POSIX/Bash world?

My preference is PowerShell. It's now open source [1], it has a wide install base, and is cross-platform. It is a bit heavy and slower to start (actually takes seconds), but the cleaness of it's record-based nature versus just string parsing is infinitely refreshing.

[1] https://github.com/PowerShell/PowerShell




You can build from source to strip away telemetrics.


"can" is doing some heavy lifting there, especially based on my experience with VSCodium (which by definition is forced to work within Microsoft's opinion of build systems)

Anyway, uh-huh:

https://github.com/PowerShell/PowerShell/blob/v7.5.1/.github... -> https://github.com/PowerShell/PowerShell/blob/v7.5.1/.github...

https://github.com/PowerShell/PowerShell/blob/v7.5.1/.github... -> https://github.com/PowerShell/PowerShell/blob/v7.5.1/.github...

and, relevant to your comment even they opt out of telemetry https://github.com/PowerShell/PowerShell/blob/v7.5.1/.github...

---

As a frame of reference, to build bash one only needs /bin/sh not a pre-built copy of bash itself https://git.savannah.gnu.org/cgit/bash.git/tree/configure?h=...


I wonder if the distros that have it in their repositories already do this.


Mac's Homebrew doesn't. I just installed it, ran the "ls" command, and saw Little Snitch block outbound connections to Akamai and Azure.


It is unlikely to be PowerShell.

On my old i386 server, this is my fastest shell:

  $ ll /bin/dash
  -rwxr-xr-x 1 root root 85368 Jan  5  2023 /bin/dash
The set of features in the POSIX.2 shell is designed to minimize resource usage.

This is simply a place that PowerShell cannot go.


i386 isn't even supported by Linux anymore and has less power than a Raspberry Pi. It's not the indicator of the future of anything. It might be nostalgic, but it's ewaste and better served by a Pi.


My mistake, my legacy rhel5 i686 on a 22nm Xeon.

This does not mean that resource-constrained environments do not exist.


Anything that's slow to start is completely unusable as a general replacement for shell scripting. For specific use-cases where the script itself would take a long time to run, a slow start may be fine, but `sh` scripts are used all over the place in contexts where you want it to do its thing and get out of the way as fast as possible (e.g. tweaking env vars or arguments before `exec`ing a binary).


During boot my shell took 2.5s to start up. Now, it took 0.9s to start up. I have trouble imagining a scenario where scripting is adequate, but a second or two of start up is too much. I'm thinking maybe high-availability migration or something. The benefits to correctness from the (optional) type-system seem worth it even there.




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

Search: