Updated

Embattled Mahmoud Abbas got a major boost in his increasingly bellicose showdown with Hamas on Saturday, with a U.S. diplomat saying he expects a crippling 15-month-old foreign aid embargo to be lifted once the Palestinian president appoints an emergency government without the Islamic militants.

• Reporter's Notebook: Hamas in Control

The new Cabinet, to be headed by internationally respected economist Salam Fayyad, is to be sworn in Sunday, just three days after Hamas seized control of Gaza and Abbas dismantled the Hamas-Fatah coalition government in response.

In Gaza, panicked residents lined up at bakeries to stock up on bread, fearing growing shortages of food, fuel and other staples as the crossings of the fenced-in strip with Israel and Egypt remained closed. Hundreds of other Gazans rushed to the border crossing with Israel to try to escape Hamas rule, but found gates locked. Israeli troops briefly fired warning shots.

Senior officials of Abbas' Fatah movement, who had fled Gaza, started reaching the West Bank. The head of Palestine TV said he had crawled for several hundred meters to evade gunfire at the Gaza-Israel crossing before making it to safety.

Across Gaza, Hamas cemented control. Deposed Prime MinisterIsmail Haniyeh replaced Abbas-allied security commanders with his loyalists, and Hamas gunmen searched homes and neighborhoods to round up their opponents' weapons. In the southern town of Khan Younis, members of the most powerful local clan refused to hand over their guns, and a firefight erupted. Hamas fighters besieged and then stormed the homes of clan members, saying they confiscated drugs and a large weapons cache.

In the West Bank, gunmen from Abbas' Fatah movement attacked Hamas-run institutions, storming the parliament and several government ministries. Chanting "Hamas Out," they planted Fatah and Palestinian flags on rooftops. They attacked Deputy Parliament Speaker Hassan Kreisheh, an independent, but parliament employees prevented the assailants from grabbing him. The gunmen left after warning government workers that those with Hamas ties would not be allowed to return.

With Hamas and Fatah tightening their grip in Gaza and the West Bank, respectively, the leaders of the two political camps traded increasingly harsh verbal attacks and challenged each other's right to rule.

In Gaza, Deputy Parliament Speaker Ahmed Bahar of Hamas called Abbas' attempt to form an emergency government illegal.

Abbas, meanwhile, angrily rejected attempts by Arab League chief Amr Moussa to mediate between him and Hamas' supreme leader, Khaled Mashaal. Abbas aide Yasser Abed Rabbo said the president would not engage in a dialogue with "killers."

In the showdown, much of the international community, including the U.S., the EU and moderate Arab states, is backing Abbas. Declarations of support were likely to be followed soon by a resumption of foreign aid to the Palestinian Authority, though it is not clear yet whether all the international funds would then be kept out of Gaza.

The U.S. consul general in Jerusalem, Jacob Walles, met with Abbas at his headquarters in Ramallah on Saturday, and said the embargo is expected to be lifted once the new government is sworn in.

"I expect that we are going to be engaged with this government," Walles said after the meeting. "I expect that early next week. There will be some announcements in Washington, specifically about our assistance and about the financial regulations."

The international community imposed the sanctions last year after Hamas won legislative elections. The boycott, which has crippled the Palestinian economy, continued even after Fatah joined Hamas in a coalition in March.

Hamas has not explained how it would run Gaza without foreign support or contact to the outside world. Israel controls Gaza's borders, wielding tremendous influence over the movement of people and goods in and out of the area.

On Saturday, there were signs of panic. One Gaza City baker distributed tickets to those waiting in line for bread. Sarifa Hadad, a mother of seven, bought $40 worth of food, including tomato paste and shortening, and was going from store to store to buy more. "They say the borders are going to be closed, so we are searching for sugar and supplies," she said.

Israel will eventually allow basic supplies into Gaza to prevent a humanitarian disaster, said Public Security Minister Avi Dichter. However, he said Israel would consider Gaza as a "terrorist entity" and try to cut off its weapons supply. He said this might require an Israeli deployment along Gaza's border with Egypt, to halt weapons smuggling.

Israel withdrew from Gaza in 2005, ending a 38-year-old military occupation.

Dozens of Gazans, meanwhile, converged on Gaza's Erez crossing with Israel in hopes of fleeing. One man was carried on top of a luggage trolley with his leg bandaged. Hassan, 21, a presidential guard trainee, said he was shot in the fighting. He gave only his first name because he was afraid of retribution.

About 150 waited at the gate separating Gaza from Israel. Some carried large suitcases, others held tiny plastic bags. One young man shouted "bye, bye, Gaza," and waved as he walked through the covered walkway that leads to the Israeli side.

Shlomo Dror, an Israeli spokesman, said only a few people, considered humanitarian cases, were allowed across.

By midafternoon, a Hamas checkpoint was erected on the road leading to Erez. Six masked Hamas gunmen, dressed in the blue uniform of the police, stopped cars, checked for IDs and prevented people from going through.

About 50 senior Fatah officials and security officers who had fled Gaza earlier reached the West Bank city of Ramallah, many gathering in the lobby of the Grand Park Hotel.

One of the refugees, Abdel Salam Abu Nada, the general manager of the Fatah-controlled Palestine TV, said he took a harrowing journey to safety, evading Hamas checkpoints, braving Israeli tank fire and crawling 300 meters to Gaza's border with Israel.

"Hamas has always targeted me. Once they fired shots are my car. And they wrote on their Web site that I am broadcasting sedition," he said. Recently, he received an ominous text message on his cellphone saying, "Your punishment is coming."

Hamas has offered amnesty to Fatah loyalists. However, several revenge killings took place after the announcement, including two on Saturday.

Symbols of Fatah control, including the Gaza City residence of the late Yasser Arafat were looted. Abbas' office said looters took furniture, including a bed, as well as presents the legendary leader had received in four decades at the helm of Palestinian politics. Hamas security forces later arrived and locked the house. Hamas denied anyone had broken into the building.