Ban government shutdowns? Some Republicans and Democrats want to make it the law Lawmakers want to end shutdowns, but aren't sure how to do it.

As lawmakers scramble to negotiate a border security compromise after the longest government shutdown in American history, some Republicans and Democrats, from freshmen to the most veteran legislators, agree on one thing: They don’t want another one.

That’s led to a flurry of bills aimed at outlawing government shutdowns amid concerns that a president, at odds with Congress, could use the tactic capriciously - at the expense of closing the government and hurting hundreds of thousands of federal workers.

Some are pushing to have such a measure added to any funding compromise this month, something that would surely be seen as a rebuke to President Trump who has threatened another shutdown in just about two weeks, when temporary partial government funding is set to run out once more.

One proposal gaining the most momentum comes from Sen. Rob Portman. The Ohio Republican introduced the "End Government Shutdowns Act" earlier this year. It was the fifth time he's tried to permanently prevent government shutdowns, but this time around, Portman has garnered 19 co-sponsors just among his GOP colleagues, with Democrats clamoring to sign on as well, according to a Portman spokesman. Perhaps most notably, two of the four GOP negotiators tapped to hammer out a government funding compromise by Feb. 15 have signed on to Portman's effort.

Under Portman's bill, if Congress fails to pass any of the 12 appropriations bills that fund the government each year, the measure would create an automatic continuing resolution, or stopgap funding bill – which would fund the government at the previous year’s levels. To motivate congressional action, it would also continually reduce federal spending levels with across-the-board cuts while any budget impasse dragged on.

Sen. Mark Warner, a Virginia Democrat, whose constituents in the Washington suburbs acutely felt the impact of the latest funding standoff, introduced the “Stop STUPIDITY ACT,” which would fund all aspects of the government except the Executive Office of the President and Congress in the event of another shutdown. To address any constitutional concerns, a Warner aide tells ABC News that the bill, formally called the "Shutdowns Transferring Unnecessary Pain and Inflicting Damage In The Coming Years Act," would apply only to future Congresses.

“This isn’t just about us being stubborn about the wall. This is really about protecting the institution and protecting those federal employees from constantly being held hostage,” Rep. Gerry Connolly, another Virginia Democrat, who supports aspects of Warner’s proposal, told ABC News.

And the Virginia senator’s effort has the imprimatur of GOP leadership.

House Minority Leader Kevin McCarthy, R-Calif., gave a full-throated endorsement of Warner’s effort on Sunday in an NBC interview.

“You want to know how you’ll never have a shutdown again? Let’s not pay the members of Congress and Senate,” McCarthy said.

Meanwhile, House Speaker Nancy Pelosi, D-Calif, a former appropriator, put her considerable political influence behind a 2011 proposal introduced by former Rep. Dale Kildee, during a meeting with columnists last week to extend funding at previous levels until some sort of deal is reached.

“We have to subject it to all the timing scrutiny and the rest of that, but and what that bill said is … any appropriation bill that does not get agreed upon in a timely fashion by the date, you automatically are going to a CR until you do come to a conclusion,” she said.

Both Democratic and Republican Senate leaders, while not endorsing a particular bill, did say Tuesday that they are behind the effort more generally.

“There certainly would be no education in the third kick of the mule,” Mitch McConnell, R-KY, said of shuttering the government. “I don't like shutdowns. I don't think they work for anybody. And I hope they will be avoided. I'd be open to anything that we could agree on on a bipartisan basis that would make them pretty hard to occur again.

New York Sen. Chuck Schumer, the Democratic leader, told reporters, “We Democrats want to negotiate in good faith and come to an agreement so…that the shutdown ends and then we look at other legislation so that we wouldn't have future shutdowns.”

Also on Tuesday, a group of freshman House Democrats introduced the “Shutdown to End All Shutdowns Act," which, in addition to funding the government at current levels during a shutdown, would prohibit the use of federal funds for lawmaker travel and require Congress to keep the floor open for business while also putting similar limitations on the use of federal funds by the White House and the administration, except in cases of emergency.

The bill from the freshmen, including members who voluntarily gave up pay during the shutdown, would also suspend wages for lawmakers and not hold it in escrow in the event of another shutdown.

But despite the momentum behind these approaches, they face resistance from some senior members of Congress, including the congressional appropriators who craft the spending bills directing billions of dollars in federal spending each year as part of Capitol Hill’s zealously-guarded constitutional authority over federal spending and revenues.

“Congress ought to do its job,” House Majority Leader Steny Hoyer, D-Md., told reporters, repeatedly dodging questions about what he might support, saying he was “reticent” about proposals that would automatically fund the government in the event of negotiations breaking down.

“I’m a little nervous about it,” Rep. Hal Rogers, a Kentucky Republican and a senior member and former chairman of the House Appropriations Committee, told ABC News. “It would interfere with the appropriations process, and would put an emphasis on not passing bills.”

Sarah Binder, a political scientist at the Brookings Institution, noted that Republicans, and not Democrats, would appear to benefit more from a proposal that would keep federal spending levels down.

“I was a little surprised given that these automatic CRs (continuing resolutions) aren’t great for Democrats and proponents of increasing spending on domestic programs,” she said. “If Democrats come to the table, it’s because they’re worried about the President using this tactic again.”