Author of the Go by Example book: mng.bz/Nw1E📚 Learn Go by fixing 1000+ tiny programs: t.ly/8UEb 🎸 Old-School Programmer from 1990. Works @grafana.

United States
Joined April 2007
#golang Pro Tip: As of Go 1.21, there are now min and max: min(2, 3) // 2 (int) max(2, 3.5) // 3.5 (float64) min("c", "b", "a") // "a" (string) Check out the spec for details: go.dev/ref/spec#Min_and_max
🚀 #golang Pro Tip: Remove a module fast using `none`: go get modernc.org/sqlite@none This will remove the module from go.mod.
7
30
4
168
Python is magical. Ruby is magical. Things can pop up from anywhere. "Where is this method came from?" Go is not magical. This is the way. #golang
The UNIX philosophy is often quoted as “everything is a file”, but that really means “everything is a stream of bytes”. — Linus Torvalds
13
37
Go is a "get things done" language. #golang
In Go, everything is passed by value. Even pointers. #golang
8
5
2
96
To become a better Gopher, be bold and study the source code of the packages you import. Not only will you better understand how they work, but you'll also learn what patterns they use in practice. #golang
2
7
1
64
Most OOP languages say: 'A cat IS an Animal' (inheritance) 🐈🧬 In Go, we say: 'A cat CAN make a sound' (behavior) 🐱🔊 Let's create abstractions around what things DO, not what they ARE. Embrace the #golang way! 💪🚀
🔥 Pro Tip: In the world of Go, clarity triumphs over brevity. Embrace clear code, even if it means typing extra lines. #golang
1
5
2
38
Idiomatic Go code is efficient. It’s more than stylish. #golang
2
29
"Go encourages programming by writing code rather than coding by designing types." — Ian Lance Taylor #golang
6
8
125
> Go 1.20 improves build speeds by up to 10%, bringing it back in line with Go 1.17. > Go 1.18 and 1.19 saw regressions in build speed, largely due to the addition of support for generics and follow-on work. 🎉 #golang
3
39
237
Start with concrete types first. Let interfaces emerge organically. #golang
To write simple and effective code, deeply understand the problem first. Complexity is a byproduct of a lack of understanding.
4
10
70
“Object-oriented programming is an exceptionally bad idea which could only have originated in California.“ — Edsger W. Dijkstra
8
12
122
In #golang, we "expect" errors, but we don't "expect" panics. 😊 Errors are our sane behavior 😱 Panics are our manic behavior
7
14
1
133
Effective Go book: Chapter 6. 🚀 Designing a concurrent HTTP client. Includes: + The concurrency pipeline pattern. + Context, cancellation, graceful stop, etc. + Functional options. + Composability. + Zero values. manning.com/books/effective-… #golang
7
45
298
Tests should not depend on each other. Let's shake'em: go test -shuffle=on So you can see which ones are messing things up. #golang
1
31
154
100% test coverage != bug-free🪳