Leury Garcia drove in the game’s only run with a two-strike, two-out  single in the ninth inning, lifting the White Sox to a 1-0 victory over  the Giants on Friday night.

Lance Lynn pitched six scoreless innings in his best start of the  season, and Joe Kelly, Tanner Banks and Kendall Graveman finished the  job,

with Graveman notching his fourth save as the Sox took the first game of a three-game series at Oracle Park.

The struggling Garcia, who went 2-for-4 to raise his average to .200,  lined a 2-2 pitch from Camilo Doval to right field with two outs,  scoring pinch runner Adam Haseley.

Gavin Sheets had reached first on Doval’s error covering first and advanced to second on AJ Pollock’s single.

Haseley, pinch-running for Sheets, scored from second, beating right fielder Mike Yastrzemski’s throw.

Lynn held the Giants to three hits while walking two. He struck out  five, including Tommy La Stella to work out of a bases loaded fix in the  first and Mike Yastrzemski with his last pitch — with a runner on  first.

Lynn caused concern in the third when Joc Pederson called time as he was  starting his windup. Lynn halted his motion and felt some apparent  discomfort, prompting a visit from training staff.

It was easily the best start of Lynn’s four outings since coming back from knee surgery. He lowered his ERA from 6.19 to 4.50.

Giants right-hander Alex Cobb pitched five scoreless innings, not  allowing a hit until Jose Abreu’s infield single to deep shortstop with  two outs in the fourth.

The Sox batted .281/.336/.406 and averaged 5.07 runs per game in June,  third-best in the American League, but they welcomed in July with a  listless attack against Cobb and x relievers.

The Sox were in dire need of stringing together wins and taking series  in July after going 8-12 in April, 15-12 in May and 12-15 in June.