好汉不吃眼前亏 hǎohànbùchīyǎnqiánkuī [idiom] a wise man knows when to retreat
A wise person does not fight against impossible odds; a person should know when to make temporary concessions to avoid immediate loss or humiliation in an unfavorable situation.