President Donald Trump urged reluctant GOP lawmakers on Thursday to swing behind a split-the-differences bipartisan budget and debt deal between his administration and House Speaker Nancy Pelosi.

Trump tweeted on that “House Republicans should support the TWO YEAR BUDGET AGREEMENT which greatly helps our Military and our Vets.” He added in a note of encouragement, “I am totally with you!”

Trump’s comments come ahead of a scheduled House vote on the two-year deal that would head off another government shutdown, permit the Treasury to borrow freely to pay the government’s bills, and lock in place hard-won budget gains for both the Pentagon and domestic agencies.

The agreement outlines a $1.37 trillion cap for the so-called discretionary accounts funded by Congress each year that permits Capitol Hill’s appropriations barons to get serious about advancing follow-up spending bills for the 2020 budget year beginning in October.

But it contains no new steps to curb spending elsewhere in the budget, rankling conservatives and lawmakers alarmed by the return of $1 trillion-plus budget deficits.

“Republicans who go along with this budget deal will lose all credibility on spending. This is budget deal is ludicrous,” said Jason Pye of the FreedomWorks conservative advocacy group. “The GOP has been misleading the American public on spending for years now. Yeah, they talk a great game on the campaign trail. But when it’s crunch time, they fold.”

Trump’s active support for the measure could stem the tide of GOP defections. At the same time, Democrats were confident of a big vote on their side.

“We’re in good shape,” said House Speaker Nancy Pelosi, D-Calif. “We want it to be bipartisan.”

Pelosi was the main architect of the measure, along with Treasury Secretary Steven Mnuchin. It amounts to a victory for Washington pragmatists seeking to avoid political and economic turmoil over the possibility of a government shutdown or first federal default.

The must-do legislation represents a rare moment of detente in Trump’s Washington. Both sides see it as being in their interest to avert the alternative: A chaotic fall congressional session that could have pinballed from crisis to crisis.

Fights over Trump’s U.S.-Mexico border wall, other immigration-related issues and spending priorities will be rejoined on follow-on spending bills this fall. The House has passed most of its bills, using far higher levels for domestic spending. Senate measures will follow this fall, with levels reflecting the accord.

The legislation would take care of the two biggest items on Washington’s must-do agenda: increasing the debt limit for two years to avert a first-ever default on U.S. payments and acting to set overall spending limits and prevent $125 billion in automatic spending cuts from hitting the Pentagon and domestic agencies with 10 percent cuts starting in January.

Washington’s arcane budget rules give each side a way to paint the deal favorably. Generally speaking, it would lock in place big increases won by both sides in a 2018 pact.

By one measure, the price tag for the legislation posts at $324 billion. But more than two-thirds of that is to simply maintain current spending levels rather than fall prey to the automatic spending cuts, known as sequestration. Another measure is $103 billion, spread over two years to Pentagon and domestic accounts, to permit modest budget hikes of 3 or 4 percentage points above current levels.

Pelosi won a little more money for domestic programs than defense, but it would be eaten up by large new costs for the census and new private sector health programs for veterans.

© The Associated Press. All rights reserved.