There's no law of nature that says that if we run out of oil, we will find an alternative energy source, rather that just going back to a different type of civilization with a much lower energy usage where most of the economy is just food production.
Sometimes I wonder if all the decarbonization tales are just story we like to tell ourselves to pretend we are in control, rather than just becoming much poorer because oil is running out and there's nothing we can do about it.
On the other hand, if we want to go really dirty, I guess there's always coal, but many countries only have low quality reserves.