If your goal is to have quiet and robotic-like good behavior, this strategy may not be a bad idea.
If your goal is to maximize student learning, student relationships, and mental health, then this approach is probably not a good idea.
Sometimes students do things that make you want to lose your temper. This is true whether you are teaching five year olds or twenty-two year olds. It is part of the job of teaching.
Learn to pick your battles. There may be times when a student does something to deserve a harsh reaction. Most of the time, though, the best way to handle student disturbances is to keep calm and stay under control. You will be glad you did.