> A nuke means that anyone who wants to invade you needs to price in a total loss of their largest city as a possible outcome. That is a great disincentive, one that Ukraine probably wishes it had against Russia.
It's even more complex than that. If Ukraine responded conventional war with nukes, it can be sure Russia would retaliate with even more nukes, practically extinguishing their statehood.
The equilibrium is reached when the exchange is equally devastating, so the only winning move is attacking first, and only if the attacked won't be able to retaliate. The Cold War never ended, just warmed a little, because it doesn't exist (yet) a guaranteed way to avoid an all-out nuclear retaliation.
Even as the aggressor, you don't want to be nuked even if it might warrant a response.
That the Cold war was cold is also a joke. It was full, full, full of hot conflicts with client states.
What it seems to have deterred is two major states warring directly.