Garment factories are spinning out T-shirts again and street markets are packed, but Haiti's wrecked capital and damaged port show the huge task ahead in repairing the economy after a huge earthquake.

The commercial downtown of Port-au-Prince is a dusty wasteland plagued by scavengers, the main port is under repair, the government barely functions and bodies are still being pulled from the gray rubble.

But even as foreign governments try to feed, treat and give shelter to the hundreds of thousands of homeless and injured, businesses are trying to get up and running again.

Street markets are packed with stalls selling fruit and vegetables and out near the airport, where humanitarian aid is still flooding in, garment workers have returned to push out clothing from Haiti's main industrial park, which managed to escape major damage from the quake.

Many workers were killed, seriously injured or lost family members in the earthquake, and others lost their homes and now need to rebuild their lives.

Aid is important, distributing food is important, but we believe the most important thing in the medium and long term is making sure these jobs are back, said Richard Coles, who runs a family garment factory in the park.

The textile sector accounts for much of the export trade in Haiti, the Western Hemisphere's poorest nation. Many Haitians live on subsistence farming and the quake may have cost its workforce one in five jobs, the government estimates.

Prime Minister Jean-Max Bellerive said Haiti lost 60 percent of its economy in 30 seconds.

Coles, a member of a national industrial group, believes light export industry will be back on track by March, however, while other local trade will take longer to recover.

Fuel supplies have returned and banks have already reopened as have wire transfer offices for Haitians overseas to send in cash to relatives.

U.S. officials working on the restoration of the city's main port say it could be ready to receive 700 shipping containers by mid-February. One pier is already receiving aid shipments, which remain a priority.

Exporters are for now turning to smaller harbors outside the capital and shipping overland. Volume is small but it makes a difference, Coles said.

GOVERNMENT OFFICES, DOWNTOWN IN RUINS

Just as the private sector slowly climbs back from the disaster, the central government is also struggling.

The presidential palace is ravaged, its white dome toppled, the Congress building is a gutted wreck and many ministries are just as damaged, leaving President Rene Preval and his cabinet to work from a temporary base at a police headquarters.

Dozens of senior officials have died. You can rebuild buildings, but you cannot replace the experience, Jocelerme Privert, a consultant to the president told Reuters. We are going to get back to work.

Earlier this week, workers used a crane to lift strongboxes out of the green-and-white planning ministry building.

They have checks inside for workers, said one of the laborers directing the crane as it maneuvered a safebox from one of the upper floors.

The downtown commercial heart of Port-au-Prince was one of the areas hardest hit.

Many businesses are in ruins, with stores and hotels crushed into dusty rubble. Garages have become chopshops where mechanics strip wrecked vehicles. Nearby looters squabble over lumber and metal scraps for building.

Standing outside his electronics store, Sandrino Montironi says his business is one of the few standing in downtown, protected by shotgun-totting guards to ward off looters. Customers come looking for generators and new cellphones.

There is no security, that's the biggest problem. People are still worried about their stores being looted, he said. If the Haitian people can put their heads together we can get over this.

(Editing by Kieran Murray)