The Greens have not been in government for the last sixteen years. It was the conservative governments under Merkel and particularly the environment and later economy minister Altmaier who openly celebrated reducing buildout of solar power [1].
As for nuclear power: any talk about lengthening their operation is utter madness. There are no fuel rods and the reactors haven't had their security checkups because they were scheduled to be shut down - and just look at France just how catastrophic nuclear power actually is (ETA: I substantially detailed that in a daughter comment, see https://news.ycombinator.com/item?id=32605337).
The government has little other choice than to keep the coal burners running at this point, as the Merkel governments have done everything in their power to hinder renewable energy buildout, and the Bavarian CSU has sabotaged cross-country high voltage power transmission lines.
[1] https://www.n-tv.de/politik/Einbruch-bei-der-Photovoltaik-ar...