At first glance, 2012 seemed to be a year that General Motors (GM -0.47%) just muddled through. The company lost market share in the U.S., fell behind Toyota (TM -1.08%) in the global sales race, and saw archrival Volkswagen (VWAGY) close in on its long-standing lead in China -- the world's largest auto market.

GM has yet to fully realize the promise of its 2009 "bailout." While GM is arguably much stronger than it has been in years, the company still seems to be lagging a few years behind Ford (F -0.41%) and other rivals.

But for all that, the General quietly made a lot of progress in 2012 – and is on track to gain more ground in 2013.

A dated product line, about to be overhauled
Some investors clearly think that GM is on the right track: The General's stock was up over 38% in 2012, even as the company's profits continued to trail those of its peers. But a look at why GM isn't making more money will also help to show why the company is in many ways on the right track as 2013 dawns.

GM's margins in the U.S., at around 7.8% last quarter, trail Ford's 12% by quite a bit. The problem? GM's product line. Ford has refreshed nearly all of its cars and trucks in the last few years, whereas GM's product line still has some aging designs that don't compete well – and that have needed big, margin-killing discounts to keep sales going.

Nowhere is that more evident than in the pickup market, where GM's older trucks have lost ground to fresher designs from Ford and Chrysler – so much so that the company had a glut of unsold models to clear out at the beginning of December, which led it to offer big discounts.

But that's a problem that might pass shortly: GM's all-new pickups are set to enter production in a few weeks. Assuming that they compete as well as GM's best, recent products (a good bet, but not a slam-dunk), GM's margins in its home market should improve significantly.

While pickups are arguably GM's most important product, this is a story that will play out again and again over the next couple of years as the company's product development push – stalled during its collapse and bankruptcy – leads to a slew of new cars and trucks.

As GM executives have been fond of pointing out recently, the company will go from having the oldest product line in North America to having the freshest two years from now. As the company releases more of those products, profits, and investor confidence, should continue to grow.

Moving forward on several important fronts
Meanwhile, GM made progress on a number of other important fronts in 2012. Key among them: The U.S. Treasury agreed to a plan to sell its remaining GM stock, the last legacy of the company's bailout, by early 2014. That will remove a huge overhang from GM's stock price, which has already risen about 13% since the Dec. 19 announcement.

Even GM's long-troubled European operation seemed to make progress in 2012, as a management overhaul and other moves led GM vice chairman Steve Girsky to say that the money-losing unit was on track to break even by 2015.

With the company's global product overhaul set to unfold over the next few years, Europe remains GM's biggest challenge. Some of GM's moves in Europe have raised investors' eyebrows, but it seems increasingly likely that the company is quietly preparing for a bold move – possibly even a bankruptcy filing by its German subsidiary, Opel.

The upshot: Slowly but surely, progress is being made
GM still has problems. Its launch of the new Chevy Malibu has been rocky, and the car hasn't made much of an impression in a crowded segment where cars like Ford's impressive new Fusion have raised the bar. The pickup glut seems likely to hurt GM's fourth-quarter profits, and Europe losses will weigh through 2013 and beyond.

But for all that, it mostly looks like CEO Dan Akerson has GM on the right track. While it's likely to continue to be a bumpy ride, GM shares should gain more ground as the company's turnaround continues to unfold in 2013.