BREGA, LIBYA—For a few fleeting hours Wednesday, Moammar Gadhafi appeared to have dealt the Libyan revolution a devastating blow, shifting the battle dramatically eastward in a muscle-flexing bid to seize back a key oil installation that helps keeps Europe’s home fires burning.

But Brega fought back. And kept on fighting, outnumbered by Gadhafi’s men five to one. Street by street, the odds broke against them. They gave ground, losing the refinery, losing the factories, losing the town’s centre.

By mid-morning, with explosions in the background, local rebel commander Khaled Kowati, was shouting into his cell phone that the end was near. Kowati, a civil engineer from Brega, told the Toronto Star his 200 men were about to lose the airport.

“There are 1,000 of them, maybe more. I think they want to destroy the refinery,” Kowati said in something approaching a scream.

“But this is our land. We will not give up. We will die for it.”

With that he ended the 45-second interview and resumed his war.

Journalists racing the 250 kilometres south from Benghazi to report on the battle anticipated Gadhafi would own the town even before they arrived.

But if Wednesday’s Battle of Brega teaches us anything, it is not to underestimate Libya’s ragtag uprising. As we sped to the scene, civilian cars in all shapes and sizes sped even faster, all crowded with armed rebels racing to the rescue. The cavalry, if you can call it that, was on its way.

It’s a barren desert expanse that curls southwest from Benghazi, a coastal highway that requires regular sand ploughing to keep its pavement clear. And more barren still on this day because of the ghibli — a hot, dry, sand-laden wind that closes around you like yellow fog.

It was through that otherworldly haze, at the western gates of Ajdabiya, the last town before Brega, that some 1,500 rebel fighters massed. More perhaps. Those too young to fight flashed V for victory, cheering on their compatriots as this mismatched army flew by, the barrels of AK-47s poking out the windows.

Less than an hour later, as the outer limits of Brega came into view, the battle had evened up — and the tide began to turn against Gadhafi’s forces. A rebel anti-aircraft gun had only just downed one of the regime’s precious Mirage jets, and rebel fighters scattered for cover as a second Mirage circled overhead in search of a target.

But there were five more hours of pitched battle to come — and a steady parade of casualties at Al Brega Hospital, where medical staff counted 15 dead and dozens more wounded, before it was over.

Four of Gadhafi’s soldiers — Libyans, in this instance, not foreign mercenaries — were captured alive. And the rest of his men were chased westward, fleeing so quickly back in the direction of Sirte that they left behind caches of weapons and ammunition for the rebels to seize.

The casualty figures are incomplete, at best. It remains unclear how many of Gadhafi’s men fell. And multiple rebel sources in Brega claimed that in the midst of the battle the regime soldiers actually retreated with the bodies of other dead and injured, as if to mask the true toll. The claims were impossible to verify under the circumstances.

Another Brega witness, Mohammed Moghrabi, told the Star that one unit of Gadhafi’s fighters seized a family of five, including women and children, and “used them as human shields” to enable their retreat against the surging rebels. Others repeated the accusation, but that too could not be verified.

Those grisly details aside, it was clear that Gadhafi’s first serious counterthrust into the rebel stronghold of the east rattled Libya’s people-powered revolution. Brega is not simply an important oil and industrial hub, but the gateway to the most populated centres of anti-Gadhafi resistance. Had Wednesday’s 15-hour battle gone the other way, Gadhafi’s forces would have been dangerously close to sensitive water and electricity generating hubs, raising the possibility of plunging swathes of the east into drought and darkness.

“Gadhafi wants Brega to show the world he controls the oil,” said Abdul Wahab, an engineer at Brega’s ammonia plant, one of several chemical facilities clustered around the refinery.

“We were afraid this day would come because we are vulnerable being down the road from his home town. But the heroes of this battle are the normal, civilian people of our city. The other fighters came later to help. But Brega saved itself.”

Dr. Ramzi Shah, a Benghazi forensics specialist, was one of 22 medical staff from neighbouring towns who answered the call to reinforce Brega Hospital, arrived at 8 a.m. as the first wave of casualties arrived.

He said he was sickened by some of the injuries, which included rebel fighters taking direct hits from heavy-calibre guns designed to down aircraft.

“Libyans have seen everything from Gadhafi. But the cruelty of pointing this kind of a weapon at another human is unimaginable.”

Another deep irony was evident in the date — March 2 marks the anniversary of Gadhafi’s hollow claim to have ceded power to Libyans, effective stripping himself of any formal title. A decision taken years ago and one that is meaningless to Libyans, who have never been in doubt of who controls them, regardless of the honorific.

If Gadhafi timed Wednesday’s assault as some sort of tacit nod to March 2, it very badly backfired. Whatever the strategic cost of the failed attack — and it may in fact have done little to weaken Gadhafi’s remaining military capabilities — the aftermath proved a massive morale boost for the rebel cause.

If the rebels were upbeat on the drive toward Brega, they were utterly euphoric on the drive home, as residents lined the highway offering a hero’s return. A cacophony of celebratory gunfire rang all the way back to Benghazi, where tens of thousands gathered on the seaside corniche in a victory gathering replete with fireworks.

Yet the traffic on the coastal highway Wednesday, perhaps significantly, was a two-way. In the other direction, moving westward toward Brega, small clusters of military vehicles were visible with heavy guns in tow — higher-calibre weaponry, liberated by the rebels from Libya’s eastern bases.

If Gadhafi has another assault of Brega in mind, he is likely to have an even tougher battle next time.