What happened

Shares of XPO Logistics (NYSE:XPO) climbed 16.7% in July, according to data provided by S&P Global Market Intelligence, as the once high-flying transportation company is beginning to regain the confidence of Wall Street after a difficult six-month stretch. XPO still has a long climb ahead if it is to reach its previous highs, but the company -- and the stock -- seems to be moving in the right direction.

So what

XPO is an industry rollup and a longtime outperfomer that came crashing down to earth late last year and into 2019 following criticism from short-seller Spruce Point Capital followed by the disclosure in February that XPO had lost its largest customer. XPO shares lost about half of their value between Oct. 1 and the end of February, and its future as a consolidate machine was called into question by a March decision to off-load its chief operating officer.

An XPO semitruck driving along a coastal road.

Image source: XPO Logistics.

Investors in recent months have been slowly warming on the company, helped by an easing in trade tensions. July saw the momentum increase thanks in part to strong earnings from top-tier transport firms including J.B. Hunt Transport Services.

Wall Street analysts have also made the case that XPO's sell-off earlier in the year was overdone, with Deutsche Bank mid-month making the company a "catalyst call" buy based on the belief that XPO's second quarter would mark a positive inflection point for sentiment.

The company rewarded that optimism in early August by releasing second-quarter earnings that came in ahead of expectations despite what it called a "soft" operating environment, thanks to cost discipline that led to margin gains. XPO also tweaked full-year guidance, saying it now expects revenue to be flat in 2019 instead of up slightly. It also raised its free cash flow guidance, and raised the low end of its adjusted EBITDA forecast.

Now what

The earnings beat provided a temporary 10% pop for the shares, but renewed concerns about trade wars weighed on shares of transport companies in the days that followed, and XPO is currently about flat for the month. Until the U.S. and China can resolve their differences, it is going to be hard for any shipping company to consistently outperform.

The real question for XPO investors is whether the company can restart the M&A machine that helped power a 3,000% return for shareholders over a 10-year period ending last fall. As the dust settles from a difficult six-month stretch, XPO is reestablishing itself as a top transport company, but it has a lot of heavy lifting to do if it's going to return to being the type of outperformer that attracted so many growth investors in years past.