>Is making death threats in order to convince somebody to stop doing something a valid way to motivate through fear?
I don't remember Linus ever sending death threats to anyone. As for the people who did send it to the OP, I think most people agree that death threats are not OK under any circumstance and that whoever did do it is an outlier and not an example of how the community behaves.
>Is cursing somebody out on a mailing list really all that terrifying?
I think it is since public shaming tends to be effective in preventing whatever behavior was shamed, as per the racist/homophobe/sexist argument.
>If it is, is that the reason Linus, for instance, does it?
I can't speak for him but if I were in charge of an important and sizable project I can see myself doing it for that reason.
>But is it really appropriate to do this, to this extent especially, to programmers who wrote bad code? Programming relies on rational, careful cognitive consideration of problems. That's the opposite of what fear inspires. Fear-based "motivation" is lousy in general, and doubly lousy for open source software.
I don't follow why it's doubly lousy for software in general. Software has its fair share of opinionated debates that are more about differences of philosophy rather than careful cognitive consideration of problems. And as for it being the opposite of what fear inspires, I'm not sure I agree. The educational system world wide uses fear effectively and it seems to mostly work (despite whatever problems you may have with it), so I don't see what would make programming special in that regard.