NBC NewsWire via Getty Images Former Defense Secretary Robert Gates said Trump was "beyond repair" when it came to foreign policy.

WASHINGTON ― Former Defense Secretary Robert Gates, who has served both Republican and Democratic presidents, sharply criticized Republican nominee Donald Trump’s ability to lead the United States, writing that the business mogul was “beyond repair” when it came to national security.

“At least on national security, I believe Mr. Trump is beyond repair. He is stubbornly uninformed about the world and how to lead our country and government, and temperamentally unsuited to lead our men and women in uniform. He is unqualified and unfit to be commander-in-chief,” Gates wrote in a Wall Street Journal op-ed published Friday evening.

Gates wrote that Trump was clueless when it came to the American military and foreign policy. Trump has praised Russian President Vladimir Putin repeatedly, threatened to not defend NATO countries, said he would “bomb the shit” out of ISIS and seemed unfamiliar with Russia’s annexation of Crimea.

“Mr. Trump is also willfully ignorant about the rest of the world, about our military and its capabilities, and about government itself. He disdains expertise and experience while touting his own—such as his claim that he knows more about ISIS than America’s generals,” Gates wrote. “He has no clue about the difference between negotiating a business deal and negotiating with sovereign nations.”

Gates ran the CIA under President George H.W. Bush and served as defense secretary under presidents George W. Bush and Barack Obama. He wrote that all the leaders he served were smart enough to listen to their advisers ― even if they didn’t take their advice. Trump, he worried, would not.

“The world we confront is too perilous and too complex to have as president a man who believes he, and he alone, has all the answers and has no need to listen to anyone. In domestic affairs, there are many checks on what a president can do; in national security there are few constraints,” he said. “A thin-skinned, temperamental, shoot-from-the-hip and lip, uninformed commander-in-chief is too great a risk for America.”

Case in point: just last week, Trump threatened to start a war with Iran over hand gestures.

Trump responded to Gates in a tweet Saturday morning, saying his leadership had been “a total disaster.”