Bad Code Will Kill You
Zen and the Art of Code Reviews
20+ years in the industry
5+ years doing code reviews
Read a bunch of blog posts
Extremely muscular body
Does code ever work the first time?
$ grep -ir fuck linux-4.17.3 | wc -l 29 $ grep -ir kludge linux-4.17.3 | wc -l 110 $ grep -ir cludge linux-4.17.3 | wc -l 1 $ grep -ir crap linux-4.17.3 | wc -l 195 $ grep -r TODO linux-4.17.3 | wc -l 4825
## Some Highlights * Wirzenius wrote this portably, Torvalds fucked it up :-) /* !!!! THIS IS A PIECE OF SHIT MADE BY ME !!! */
$ grep -ir fuck node-v10.5.0 | wc -l 25 $ grep -ir kludge node-v10.5.0 | wc -l 22 $ grep -ir crap node-v10.5.0 | grep -v scrap | wc -l 9 $ grep -r TODO node-v10.5.0 | wc -l 2904
## Some Highlights * **help:** fuck it. just hard-code it ([d5d5085](https://github.com/zkat/npx/commit/d5d5085)) * IOW it's all just a clusterfuck and we should think of something that makes slightly more sense.
$ grep -ir fuck java-10.0.1 | wc -l 1 $ grep -ir kludge java-10.0.1 | wc -l 16 $ grep -ir crap java-10.0.1 | grep -v scrap | wc -l 3 $ grep -r TODO java-10.0.1 | wc -l 2155
## Some Highlights if (uri == null || uri.length() == 0) // crap. the NamespaceContext interface is broken // forces us to clear out crap up to the next * TODO: wrapping message needs easier. in particular properties and attachments.
But have to be repeated every time
Microsoft: 1 QA / dev in the 90s
Today: 1 QA / 3 devs
I couldn't explain my code to a junior. That means I don't really understand my code.
Do not give orders; ask questions
Maybe ask questions instead of giving orders?
Isn't it faster to change it than to argue?
Could you accept criticism gracefully?
Knowledge is shared around
Disseminate coding culture
Status updates are much faster
It takes long, but not doing it takes longer
Blame is spread
Other people reviewed
Go straight to the solutions