Beat the grass and startle the snake
Long long ago, a county magistrate named Wang Lu worked in present day Anhui province, East China. Wang Lu was very greedy and took many bribes. One of his secretaries was equally corrupt, and often schemed for Wang Lu's deeds.
One day a man went to the magistrate to lodge a complaint against the secretary. The secretary's crimes were almost the same as the crimes the magistrate himself committed. Wang Lu was so frightened, he forgot his proper role in handling the case. Instead of issuing a judgment, he couldn't help writing these words concerning the complaint: "By beating the grass, you have startled me who am like a snake under the grass!"
The above story provided the idiom "Beat the grass and startle the snake". The original meaning is that punishment for someone can serve as a warning to others. But people now use the idiom to indicate that premature actions which put the enemy on guard.