TRIPOLI Residents of the Libyan capital Thursday scrambled to find supplies, exploiting lulls in the battles still being fought in parts of the city to venture out of their homes and queue for bread.
Two days after rebels stormed the compound that was the seat of Muammar Gaddafi's rule and forced him into hiding, most of Tripoli was free of violence but chaotic.
But even in districts that had seemed calm, fierce gunfights broke out suddenly, underlining the fact the rebels' grip on security in this city is still fragile.
The Corinthia hotel, a short walk from the central Green Square -- renamed Martyr's Square by the rebels - and in an area that had seemed firmly under rebel control, was at the center of a brief battle.
Rebel fighters positioned in the grounds of the hotel used anti-aircraft guns and rocket-propelled grenades to fire at snipers in buildings nearby. Other rebel gunmen positioned themselves on the hotel roof.
Foreign journalists staying in the hotel -- some of whom had transferred there after escaping another hotel where Gaddafi loyalists had been holding them -- moved away from the windows to avoid being hit.
The fighting died down after about an hour.
There were other gunbattles being fought: around the Bab al-Aziziya compound which was the seat of Gaddafi's rule until he vacated it, and in the Abu Salim neighborhood, in the south of the city.
Away from these troublespots, people who had spent days in their homes eking out supplies were tentatively emerging.
There was more traffic on the streets, where until now the only vehicles were the rebels' pickup trucks with sand smeared on them for camouflage.
Bakeries were among the only businesses open, and outside these long queues had formed. A group of men in one neighborhood began to load trash that had been piling up in the streets into a truck.
"The security has improved in many parts of the city compared to yesterday," said Said al-Shaab, an engineer who was volunteering to clear the trash. "People are starting to come out of their houses."
Nearby, residents set up a makeshift medical clinic, citing the fear of snipers on the route to the hospital.
The rebels' National Transitional Council, backed by Western powers, has said it will implement a plan to restore order and stop Tripoli descending into the kind of anarchy experienced by the Iraqi capital after the fall of Saddam Hussein.
But the only evidence of any kind of organised rebel authority in the streets were the many checkpoints. Manned by rebel fighters, they checked cars to make sure they were not carrying weapons.
Among the fighters not involved in battles, there was time to savor their victory.
At the Bab al-Aziziya compound, fighters were still shooting their weapons in the air in celebration, 48 hours after their forces swept in.
They climbed onto a statue of a gold fist holding a U.S. jet, erected by Gaddafi to mark a confrontation with the United States in the 1980s.
A few kilometers (miles) away, in a clearing by the seafront, stood at least 100 rebel vehicles. They were part of a force which had arrived in the city from Misrata, a rebel stronghold in the east, to help clear the city.
But with the fighting confined to small pockets, they had little to do. Some lay on blankets and others cleaned their weapons. "Gaddafi is finished," said one.
(Writing by Christian Lowe and Giles Elgood; Editing by Matthew Jones)