News for hackers. Stuff that matters.
Re:.NET for Beginners (2020) by turtlebits on Wednesday April 21, 2021 @12:14AM (#26885362)
I've tried to get started with F# on Mac twice, once a few months ago, and 18 months before that. Could not get it working. When the official getting started guides don't work, that is a very bad sign. I will be staying away.
Re:.NET for Beginners (2020) by pianoben on Wednesday April 21, 2021 @12:23AM (#26885394)
It's regrettable, but F# has never seen anything like the kind of support C# and VB.NET have. It was and remains something of a "hobby" product, albeit one that sees lots of use in some specialized industries.

Although F#-the-language is top-notch, the surrounding bits - editor experience, documentation, libraries, tooling - just don't get the investment they need to be on par with the sibling languages.

What I mean to say is, don't judge .NET just by your experience with F#. C# is the happy path.

Re:.NET for Beginners (2020) by andix on Wednesday April 21, 2021 @08:07AM (#26888506)
That's weird. I just tried the minimal example on alpine, and it works right out of the box.

Installing .NET 5 should be easy on macOS as they even provide an installer.

  # Start fresh alpine
  docker run -it alpine

  # install tools and .NET 5.0
  apk update && apk add wget bash vim icu-libs krb5-libs libgcc libintl libssl1.1 libstdc++ zlib
  wget https://download.visualstudio.microsoft.com/download/pr/21fdb75c-4eb5-476d-a8b8-1d096e4b7b14/c1f853410a58713cf5a56518ceeb87e8/dotnet-sdk-5.0.202-linux-musl-x64.tar.gz
  mkdir -p $HOME/dotnet && tar zxf dotnet-sdk-5.0.202-linux-musl-x64.tar.gz -C $HOME/dotnet
  export DOTNET_ROOT=$HOME/dotnet
  export PATH=$PATH:$HOME/dotnet

  # create f# project
  mkdir my-fsharp-demo && cd my-fsharp-demo
  dotnet new console -lang f#

  # run project, it will show "Hello world from F#"
  dotnet run
Or did you have issues with the IDE?
Re:.NET for Beginners (2020) by paranoidrobot on Wednesday April 21, 2021 @12:47AM (#26885520)
When people talk about .NET, they're mostly always talking about C#.

Sure, there's a bunch of other languages that run on the CLR - but for the most part, the broadest, most well tested, path is doing stuff in C#.

Re:.NET for Beginners (2020) by manigandham on Wednesday April 21, 2021 @01:11AM (#26885642)
What was the error?

Also like the others say, F# on dotnet is like Groovy for the JVM. It's nowhere near the popularity. Any reason you didn't try C# instead?

Re:.NET for Beginners (2020) by xbar on Wednesday April 21, 2021 @02:07AM (#26885935)
It seems like you understand the story for both of them. Any reason why F# is not a valid starting point language on Mac?
Re:.NET for Beginners (2020) by oblio on Wednesday April 21, 2021 @06:31AM (#26887659)
Because it's a community language. Microsoft doesn't officially support it fully. So you have 20-30 or however many volunteer devs (probably fewer) working on it in their spare time.

If you're just getting used to the platform, you're shooting yourself in the foot by going with niche setups. Try C# first to figure out your way around the platform and then branch out, not the other way around.

Re:.NET for Beginners (2020) by nojito on Wednesday April 21, 2021 @06:41AM (#26887730)
>Microsoft doesn't officially support it fully.

Nonsense all you have to do is install the dotnet sdk and run a single line in your terminal.

    dotnet new console -lang "F#" -o "project"
Re:.NET for Beginners (2020) by oblio on Wednesday April 21, 2021 @06:48AM (#26887787)
Yeah, it's also included in VS classic, if you want to get super fancy. Does it get the same level of support as C#? Hardly. Do bugs get fixed as fast? Maybe.

I think there was a Microsoft article that summed it up nicely: there are millions of C# developers (ergo the focus), tens of thousands if not low hundreds of thousands of VB.Net developers (ergo the life support) and maybe hundreds or low thousands of F# developers (ergo the fact that Microsoft offers some integration points but expects the already small community to develop and polish the actual implementation).

It took F# several years to fully get supported on .NET Core (type providers and such). I know, because I was watching the Github issue for it for at least 2 years).

Re:.NET for Beginners (2020) by phillipcarter on Wednesday April 21, 2021 @11:30AM (#26890960)
It is. The OP was likely confused with a tool or had a specialized use case tied to Windows that they're not communicating. All the official guides for getting started work. Using specialized tools or components meant for Windows development (e.g., Type Providers not ported to support .NET Core)on a different OS may not work so well.
Re:.NET for Beginners (2020) by Multicomp on Wednesday April 21, 2021 @07:31AM (#26888181)
It's valid, just clunky to get going the first time. F# dev team is only ~7 people at MS, the rest is community supported projects and github issues. So while F# devs measure in the 10,000s, C# devs measure in the 100,000s