3 ms·
There are good reasons to give Go good will: Simplicity: Editor, GitHub, golang download. I have a working dev env for a LOT of use cases. Sudo apt install vi
by zer00eyz 3y ago
There are good reasons to give Go good will:
Simplicity:
Editor, GitHub, golang download. I have a working dev env for a LOT of use cases. Sudo apt install vim git wget tar. wget golang, untar, set env var. I have a script to do it for me on Debian boxes. Python, ruby, php are pretty close. IM guessing C# is a bit more complicated but not by much.
Dependency and library management. GO wins vs python(venvs), ruby, node, php... go mod and how it deals with pinning, pulling from GitHub. Again I dont know what C# has here but go feels both magical, and easy to understand on this front.
go build / go run. The fact that is this easy and fast to get to a running binary is impressive. I had a badly behaving container the other day and the residents of it were not giving back helpful errors. One go program (sub 100 lines) later I was getting usable error messages and quickly worked through the network issues. There are plenty of go apps that work like this! Mediamtx is great (RPI cam server) just grab the binary blob and go... The same thing in python is gonna be a lot more complicated.
Testing: A friend of mine and I recently started a project together and his commentary after coming from working on large ruby and node projects is "how is this testing this fast". GO is eating its own dogfood here with its concurrency model. IM guessing that, C# can run the same way.
Golangs good will isnt because it is the best at something. If were comparing features go is gonna come in 2nd or 3rd or 4th every time. Thats the thing, go is consistently very good at feature "X". It's not the best but it remains in the top 5. Speed, concurrency, compile time, ease of setup, ease of deployment, portability, scaling...
Golang is the Toyota of programing languages. Lovable in its reliability.
- withinboredom 3y agoWhy do you bother commenting if you don't have any experience in the other language? With C#, you literally just `apt install` the cli and it keeps up to date. I write go every weekend, and spent years in C#. I still don't know how to properly install go and I have to run it in docker containers. It's so undocumented (or rather the documentation was lacking at least a few years ago and I've not bothered checking because my workflow works for me), that I got lost as a new go dev. As far as building and running ... C# is on par with Go. There's really not much difference, at least from the cli. Editors ... I dunno. I pay for a visual studio license and the IDE is simply magical (esp with resharper). I use goland for go, and these two IDEs are barely comparable in some respects. The testing story in C# is something to be desired. I would rather build a random project to test my code than write tests in C#. It's a mess over there. But yeah, if I were to start a project completely from scratch, I'd choose PHP over either of them, so maybe I don't know what I'm talking about. I'll see myself out.
- zer00eyz 3y ago>>>> It's so undocumented (or rather the documentation was lacking at least a few years ago and I've not bothered checking because my workflow works for me) Massive improvements from the days of early go. Between ease of install (Mac, Linux, haven't looked at windows in 2 ish years) and how it deals with packaging (go mod) there has been a ton of progress here. I have not used C# in at least a decade. My knowledge is dated! (python, ruby, node, c, and rust are all much more recent). It wasnt a bad language at the time but was very MS centric. And installing it on linux is a bit more complicated than "apt install" sadly. As someone who wrote PHP for years (and it paid me well) I would say that you should take a look at installing go "from scratch" on your local system ( https://go.dev/doc/install https://go.dev/doc/install ) and building a few throw away tools!
- ryanjshaw 3y agoIf you haven't used C# in a decade you missed that .NET Framework has been completely rewritten as open source .NET. To install, it's literally just: apt-get install dotnet-sdk-8.0
- neonsunset 3y agoand then getting helloworld to run is literally dotnet new console -o MyConsole && cd MyConsole && dotnet run (dotnet run uses debug build by default, it's very similar to cargo) as for package management, it is dotnet add package {name} by far one of the best ones, and when you need to manually edit .csproj, it's as easy as cargo.toml.