See http://www.juancole.com for details of the uprising in Libya's capital, Tripoli, emanating from the working class districts in the eastern part of the city. With rebel forces having now captured most of the key towns around Tripoli and moving in, and with many of his top officials defecting, it looks like the end is near for the Qaddafi regime, one of the longest ruling in the world at over 40 years.
Shortly after the uprising began I was one of the first to forecast (here) the serious possibility of a partition and stalemate between the rebel East and the loyalist West. This was based on the long historical, ethnic, religious differences between the old Roman province of Cyrenaica in the East and Tripolitania in the West, and for many months it looked as if that would be the case, with the border at Brega in the center of the main oil region. But things have finally gone the rebels' way after a long time and external support by NATO (or some of it).
The main kicker in the fall of Qaddafi and the end of the stalemate has been that Qaddafi was never able to fully control the West. In particular, besides the coastal city of Misrata going to the rebel side, the Berbers in the mountains in the West were never subdued, and it was they and other tribes gradually taking towns in the deep South and then finally coming down out of the mountains to start taking other coastal cities and now moving in on Tripoli that have been mostly responsible for this change. The great irony here is that Qaddafi himself is of ethnic Berber origin. However, he had rejected the identity and become Arabized and made insulting remarks about other Berbers, who are now going to get their revenge.
Before he falls it may be important to remind ourselves of some curious history of Qaddafi. In the years shortly after he first took power, he played an important role in the changing political economy of oil in the world, particularly when he nationalized the Getty Oil Company's operations in Libya in 1970. That led to two things, as I described in my 1981 JPKE paper, "The Megacorpstate and the Acceleration of Global Inflation." One was that Getty had been the main independent operating in the Middle East, not one of the Seven Sisters, and had played a competitive fringe role in keeping oil prices low, which ended, thus putting more power in the hands of the producers generally. The other was that it touched off a wave of nationalizations of oil holdings throughout the OPEC nations, with the OPEC oil price increases in 1973 coming from countries largely in control of their own oil supplies. Many saw this as a progressive anti-imperalist and anti-colonialist development, although given the dictatorial and corrupt (and often reactionary) nature of most of these regimes, this has not turned out as many had hoped.
In the end, Qaddafi's own regime was an example. There were many progressive things done by his regime initially, somewhat along the lines of what the Ba'athists in Iraq did with their oil money, free education, building of hospitals, and so on. However, over time this all became degraded as the corruption and repression by the dictatorial regime became worse and worse, and more and more groups became unhappy with his rule, until we have finally reached the point we are at now, with rebel forces on the verge of removing him after his long rule. One can only hope that the successor will be better than the one in Iraq, and given the lower key role the US has played, with, as Juan Cole notes, a rebel uprising in Tripoli itself now involved and Libyans themselves overthrowing the regime rather than the US (or other foreign) military, there does seem reason to be at least somewhat optimistic about what may come out of this.