Hacker News new | ask | show | jobs
by cletus 1949 days ago
Why? Well, for one, Go produces a statically linked binary and C# requires a runtime be installed.

If we’ve learned nothing from Java and Python, it’s that managing runtimes and environment can be a huge pain point.

EDIT: swipe keyboard put ringtone instead of runtime and I missed it. Corrected.

4 comments

>C# requires a ringtone be installed.

This confused the hell out of me until I realized it's supposed to be runtime.

On the other hand, would you be surprised to learn the .NET runtime includes a ringtone?
That's probably why it confused me so much; I couldn't rule out that interpretation reliably enough to interpret it as a typo.
Thanks. I assumed it was an allusion to the .Net runtime having a bunch of unnecessary crap built into it, including a ringtone for some arcane reason.
Autocorrect: turning simple, obvious mistakes into opaque, irrecoverable mistakes.

It's never been clear to me why someone would want this.

> Go produces a statically linked binary and C# requires a runtime be installed

Not true since .NET Core 3.

$ dotnet publish --self-contained --runtime osx.11.0-x64 -p:PublishSingleFile=true

Not disagreeing with you, but just to be pedantic:

In .NET Core 3, you can build and distribute a single-file executable which, when run, will actually unpack an executable and a ton of DLLs into a temp directory, and run it from there.

In .NET 5 they changed it, so that when you build a "single-file" executable, you actually get an executable plus a few DLLs, which must be distributed together.

With C# and Java, we have learned that time and battle tested VMs can remove terrible pain points in proper hands.
To be fair, I have found Java’s JRE to be relatively painless. It’s fairly simple to have multiple installed and choose which one to use as a command line option.

Python OTOH...