Minnesota did something really cool in 2007. As part of its Next Generation Energy Act, which aimed to reduce per capita fossil fuel use 15 percent by 2015, it effectively barred utilities from buying electricity from any fossil fuelburning power plants built after July 2009 — unless the carbon emissions of those purchases were entirely offset.

In response, North Dakota, which gets a staggering 79 percent of its power from dirty coal, did something decidedly uncool. It sued its neighbor in 2011, claiming the air-cleansing and climate-protecting rule violated federal law because it limited interstate commerce.

And on Friday, a federal judge ruled in favor of North Dakota. The Minneapolis Star Tribune reports:

U.S. District Judge Susan Richard Nelson enjoined [Minnesota] from enforcing key sections of the law, which North Dakota coal and utility interests said hampered their ability to find buyers for power from existing coal-fired generating plants or to plan for new ones. …

Under Nelson’s order, Minnesota can’t enforce state restrictions on electricity imports from new power plants that increase greenhouse gases. No Minnesota utility has announced plans to do that. But the order, if upheld, could open the door to Minnesota utilities buying more coal-generated power from other states.

North Dakota’s attorney general described the ruling as a “complete victory.” Minnesota Gov. Mark Dayton (D) was decidedly less chipper — but he vowed to appeal.

“North Dakota operators propose to build new, coal-fired power-generating plants without offsetting emission reductions,” Dayton said. “Prevailing winds will carry those toxic emissions directly into Minnesota. That shameful practice should not be permitted by either the state or federal government.”