4 ms·
> I would probably choose Go for core infra for being able to move quickly as a developer At the company I used to work at it took nearly a 1000 lines to repla
by Nimitz14 8y ago
> I would probably choose Go for core infra for being able to move quickly as a developer
At the company I used to work at it took nearly a 1000 lines to replace an 80 line bash script. So I can't help but laugh at this statement.
- feketegy 8y agoSince when LoC is a meaningful metric?
- dogma1138 8y agoSince always but it depends on what you actually take into account. More LOC means more opportunities for error, and more resources needed to review that code and more time required for a new developer to get familiar with the code base. That said if you have 85 LOC vs 1000 it usually means that the 85 LOC “app” used a metric ton of external dependencies which are on their own a good source for problems. When comparing apples to apples (as in both apps use dependencies equally) I don’t see how such delta can be caused by using a different language, even using assembly would likely not cause this much inflation.
- vrazj 8y agoI can replace those 1000 lines with a bash script of 1 line that just calls the Go program ^_^
- barbecue_sauce 8y agoI've helped port some bash-based CLI tools to Go. The amount of code produced was pretty similar, just some overhead for typing and adapting some of the `awk` and `sed` functionality to be self-contained in the program. What kind of stuff was this 80 line bash script doing that resulted in over 12.5 times more code?
- deleted 8y ago[deleted]
- deleted 8y ago[deleted]
- TheOtherHobbes 8y agoHow well did the bash script handle exceptions?