When the Green/Social Democrat coalition under Schröder decided on stopping nuclear the idea was to largely exchange that for renewables (and the German wind and solar industry was leading in the world at the time). This would have been a much bigger step toward energy independence. The coal, nuclear and gas lobby (note that they typically are the same lobbyists) strongly pushed to reverse that decision and the Conservative, free Liberal coalition under Merkel initially reversed the decision, but at the same time was generally pushing for the cheapest energy solutions, which was largely gas. The strong regulations put into place for wind and solar at the time largely destroyed Germanys wind and solar industry, because domestic demand Collapsed.
It is important to remember that Germany has still very strong manufacturing industries who hold a lot of sway over the government. When Fukushima happened public sentiment went strongly towards quiting nuclear again. There was not really much opposition from industry either, because nuclear was more expensive than gas so we saw an even stronger push toward gas.