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

I always wonder why people write such projects with Go, I understand the performance benefits but I don't see it in this use case, and it's such a verbose language.


There’s a ton of acceptable reasons for it, and many of them have nothing to do with the relative fitness of Go to the task.

A couple easy-to-reach-for examples are: the author could write this faster in Go than another language, because of their familiarity; or the author deliberately wrote it in a language to learn something new or try something.


I understand, it's just that I often see projects that are a natural fit for a scripting language written in Go, specifically, it's rarer with Rust even. I wonder why that is.


To me go is a scripting language. Bash doesnt have great concurrency or type checking. When I was pulling some discord and slack it got real slow with curl and unmanageable with bash. Few hours later i was done with it in go and it was super fast

I often have to do similar at work where you could just bulk process say ALB access logs with bash into some simple stats, And it would work but in the time it took for bash to complete which was about 7 days per days of logs on the services that I was working on I was able to write go code that did it in a under 30 minutes for a day of logs. I was also able to easily make it where it output to parquet instead and then started pulling the data up in Jupiter notebooks and being able to get every stat I ever wanted as opposed to chucking away 99% of the data and bash. That was also able to keep my computer mostly active and maximizing bandwidth and CPU.

And if it's in go it's entirely portable cross-platform and I can build a compiler binary I can just hand the people to do the same thing. Scripting languages require a lot of environment set up and libraries and specifics that are not always true on other people's machines.

And finally as the other person said I'm actually just good at go so why would I learn bash or another scripting language that's actually not as good for this solution space


I think there's a lot of personal preference here, but for me "projects that are a natural fit for a scripting language" would be one-off 100-line scripts.

I think for a CLI tool such as this with 38 kloc and used by others, I'd personally be more productive using a strongly typed language (such as Rust) as the compiler will catch many mistakes before I run it.

But as I said, there's a lot of personal preference... I don't know how much that also applies to Go and you definitely could write this in Python if you wanted to (although I'd use mypy for maintainability).

I also agree with your parent, familiarity and just liking to use the language are big factors when choosing a language, even more for side projects.


Scripts are more difficult to distribute to end users.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

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

Search: