Willy Adames and Patrick Bailey hit home runs, Joel Peguero and Ryan Walker pitched out of late jams, and the San Francisco Giants made it two straight over the visiting Arizona Diamondbacks with a 5-3 victory on Tuesday.

Robbie Ray remained unbeaten against his former team with a third consecutive win, combining with four relievers on an eight-hitter as the Giants (74-71) won for the 13th time in the past 16 games.

San Francisco trails the New York Mets (76-69) by two games for the final National League wild card.

It took all of three batters for the Giants to take a 3-0 lead. After Diamondbacks starter Zac Gallen walked Heliot Ramos and Rafael Devers to begin the last of the first, Adames launched his 28th home run of the season, a three-run shot that gave the hosts the upper hand for good.

Bailey’s homer, his fifth, opened the last of the fifth and put the Giants up 5-2 after the Diamondbacks had gotten to Ray for two runs in the top of the inning.

Ray (11-6) was pulled after the fifth, having allowed two runs and three hits. He walked two and struck out five.

Seeking to end a two-game losing streak, the Diamondbacks (72-74) got within 5-3 on an RBI single by Ildemaro Vargas off Giants reliever Matt Gage with one out in the sixth.

Peguero took over with the potential tying runs in scoring position and struck out Tim Tawa and pinch-hitter Adrian Del Castillo to end the threat.

Walker entered in the ninth with a two-run lead, but he immediately got into trouble when pinch-hitter Jake McCarthy singled and Del Castillo walked.

However, the San Francisco closer induced pinch hitter Connor Kaiser to bunt into a forceout at third base, then got pinch hitter Alek Thomas to pop up and Ketel Marte to ground out for his 15th save.

Matt Chapman added a double for the Giants, who had only five hits, three of which went for extra bases.

Tawa and Blaze Alexander collected two hits apiece for Arizona, which went 2-for-9 with runners in scoring position.

Gallen (11-14) yielded all five Giants runs on five hits in 6 2/3 innings. He walked three and struck out three.

–Field Level Media

More San Francisco Giants Coverage on Sactown Sports

Christian Koss and Heliot Ramos each drove in two runs in a five-run sixth inning, Jung Hoo Lee collected three hits, including a home run, and the San Francisco Giants outlasted the visiting Arizona Diamondbacks 11-5 in the opener of a three-game series Monday night.

Logan Webb made his 30th start of the season a winning one, limiting the Diamondbacks to one earned run (four total) in six innings as the Giants won for the seventh time in their last eight home games.

After a bases-clearing triple by Jake McCarthy had helped Arizona play the Giants evenly at 4-4 through 5 1/2 innings, the hosts took charge in the last of the sixth after an error, a walk and a bunt single by Lee loaded the bases with no outs against Diamondbacks reliever Brandyn Garcia (0-1).

Koss then lashed a tiebreaking, two-run double to right field, after which Patrick Bailey added a sacrifice fly and Ramos his 17th homer, a two-RBI shot that made it 9-4.

Read More:

Five-run inning helps Giants top Diamondbacks

When is the next San Francisco Giants game?

Monday, September 8th – Wednesday, September 10th – vs. Arizona Diamondbacks
Friday, September 12th – Sunday, September 14th – vs. Los Angeles Dodgers
Monday, September 15th – Wednesday, September 17th – @ Arizona Diamondbacks
Thursday, September 18th – Sunday, September 21st – @ Los Angeles Dodgers
Monday, September 22nd – Wednesday, September 24th – vs. St. Louis Cardinals
Friday, September 26th – Sunday, September 28th – vs. Colorado Rockies

Thank you for reading SactownSports.com. Follow us on Twitter and Google News, and subscribe to our YouTube channel.