The core of the idea of someone being "passive-aggressive" is the idea that you never know where you stand with someone; if you're very clear about what things you're unhappy about and also what you're happy about, that's less of a concern.
For specific structures, I've often heard people involved in military leadership describe a formula of "praise-criticise-praise", which seems to be an attempt to run this balancing act on a personal level. "Whew, this was a big project you got done! This bit of code is absolutely bonkers. Everything other than that looks great to me, though."
Another technique is to make sure that people hear things from you not just when you're annoyed about something, but also when you're impressed. (Or, when you're not super impressed, talk up their areas of basic competence.) That gives you more leeway to criticize bluntly without impacting morale, and also makes people more eager to please. (Yes, a lot of leadership practices are manipulative as hell. Try to manipulate people without destroying their mental health and happiness please, that's super abusive and also counter-productive.)