Editor's note: This story has been updated throughout.

Warren Buffet is making a play for Texas’ largest electric transmission utility.

Berkshire Hathaway, the famed billionaire’s multinational conglomerate, unveiled a roughly $18 billion deal Friday to buy Oncor, whose roughly 120,000 miles of transmission and distribution lines deliver power to more than 3 million homes and businesses in North and West Texas.

If approved, the deal could help deliver Energy Future Holdings, Oncor’s parent company and Texas’ largest power conglomerate, from one of the largest corporate bankruptcies in American history. That company, which filed for Chapter 11 bankruptcy in 2014, is saddled with about $50 billion in debt.

“Oncor is an excellent fit for Berkshire Hathaway, and we are pleased to make another long-term investment in Texas — when we invest in Texas, we invest big,” Buffett said in a joint news release from Berkshire Hathaway and Oncor.

The proposed merger would need the sign-off of the Delaware judge overseeing Energy Future Holdings’ bankruptcy, along with approvals from the Public Utility Commission of Texas and federal regulators.

Berkshire Hathaway would pay $9 billion cash for Oncor and assume its debt, making the deal worth roughly $18 billion.

Bob Shapard, Oncor’s CEO, called the latest proposal “a great outcome for Oncor.”

“By joining forces with Berkshire Hathaway Energy, we will gain access to additional operational and financial resources as we continue to position Oncor to support the evolving energy needs of our state,” he said in a statement.

Berkshire Hathaway is venturing where other companies have stumbled. Over the past two years, the Ray L. Hunt family of Dallas and Florida-based NextEra Energy have separately tried to buy Oncor, Energy Future’s most coveted asset. Both saw pushback from consumer advocates — those concerned about the deals’ impact on Oncor’s financial health, independence and rates it charges — and failed to gain full approval from the state’s Public Utility Commission.

Berkshire Hathaway suggests this deal will be different. The company circulated a document with 44 regulatory commitments that it says parties that might intervene at the utility commission have already agreed to.

Brian Lloyd, executive director of the Public Utility Commission, on Friday applauded those efforts and said the deal “fortifies” a "ring fence" around Oncor, a financial and decision-making buffer that would insulate Oncor from any future challenges at Berkshire Hathaway.

When Energy Future was formed 10 years ago, utility commissioners insisted on a financial and corporate ring fence around Oncor to keep bankruptcy from dragging it down. It worked, keeping Oncor financially healthy even as Energy Future sank.

In a statement, Lloyd said Oncor and Berkshire Hathaway were proposing “additional assurances regarding Oncor's independence, financial integrity and commitments to invest in infrastructure, cybersecurity and system reliability.”

Under the proposal, Oncor’s headquarters would stay in Dallas, and it would remain locally managed.