EU obviously has many reasons to shift to renewables, but a huge amount of urgency was provided by the Russia/Ukraine war. There was both effort to shift supply to other countries, and reduce overall demand.
"A regulation on co-ordinated demand reduction measures for gas: This targets a 15% voluntary reduction in EU gas demand between 1 August 2022 and 31 March 2023, compared with its five-year average. The European Commission has adopted the European Gas Demand Reduction Plan with best practices and guidance for member states to help them reduce gas demand."
https://www.iea.org/reports/how-to-avoid-gas-shortages-in-th...
"In March 2022, the European Commission and International Energy Agency presented joint plans to reduce reliance on Russian energy, reduce Russian gas imports by two thirds within a year, and completely by 2030.[15][16]
In April 2022, the European Commission President Ursula von der Leyen said "the era of Russian fossil fuels in Europe will come to an end".[17] On 18 May 2022, the European Union published plans to end its reliance on Russian oil, natural gas and coal by 2027."
"A fully open study from Zero Lab at Princeton University published in July 2022 and based on the GenX framework concluded that reliance on Russia gas could end by October 2022 under the three core scenarios they investigated – which ranged from high coal usage to accelerated renewables deployment.[63][64][needs update] All three cases would result in falling greenhouse gas emissions, relative to business as usual."
https://en.wikipedia.org/wiki/2022–2023_Russia–European_Unio...