MILWAUKEE — Home runs have been key to the Milwaukee Brewers' production this season.

The suddenly resurgent Brewers hit five more Wednesday, including Manny Pina's deciding two-run shot in the eighth inning that lifted the Brewers to a 7-6 win over the Pittsburgh Pirates.

"That's our team," Pina said. "Swinging the bat, hitting homers, bringing in a lot of runs. That's why we're winning."

Keon Broxton homered twice and Neil Walker and Travis Shaw also went deep as Milwaukee completed a sweep of the two-game series with its fourth straight win after an extended offensive slump.

"It's certainly fun when you hit home runs," Brewers manager Craig Counsell said.

Pina's one-out shot to right field came off Pirates reliever Juan Nicasio (1-5). The 30-year-old rookie glanced into the Brewers' dugout before watching the ball disappear over the outfield wall.

"The clubhouse, the dugout, we're feeling the energy," Pina said. "We feel like this is the team we used to be in the first half."

The Pirates grabbed an early lead on Josh Bell's run-scoring single. Pittsburgh extended the lead to 4-0 in the third on consecutive two-out singles by Andrew McCutchen, Bell and David Freese.

The Brewers broke through in the third on Broxton's leadoff home run. After Eric Sogard walked, Walker smacked a homer against his former team to cut Milwaukee's deficit to 4-3.

Shaw's leadoff homer in the sixth, the third home run off Pittsburgh starter Gerrit Cole, tied the score.

Cole, who entered the game having won his last seven starts on the road, gave up four runs and five hits in six innings. He struck out nine and walked three.

"They are a dangerous club," Cole said. "It is just frustrating to get spotted that (lead) and not be able to hold it. That's kind of the sour taste in my mouth right now."

Pittsburgh regained the lead in the seventh on Josh Harrison's RBI single. John Jaso scored from second base, sliding in just ahead of the tag, a call that stood after a brief review.

The Brewers tied it again in the bottom of the inning when Broxton led off with his second homer of the game, a shot to left off reliever George Kontos.

Bell led off the eighth with a triple and scored on Adam Frazier's single off Milwaukee reliever Anthony Swarzak (1-0).

Brewers starter Jimmy Nelson, who allowed a career-high 10 runs in his previous outing, settled down after the shaky third inning, retiring 11 consecutive batters during one stretch. He gave up five runs, three earned, and eight hits in 6 1/3 innings. Nelson struck out seven and walked one.

Corey Knebel earned his 24th save in 29 chances.

ADDED MOTIVATION

Broxton started in centre field after watching infielder Jonathan Villar get his first-ever start at the position on Tuesday night.

"I'd be lying if I said it didn't," Broxton said when asked if the decision served as motivation. "It definitely does. I want to be out there playing and helping the team. But if I'm not doing it at that time, I have to be respectful of what Counsell wants." Counsell praised Broxton's work ethic. "He's worked on his game tremendously hard," Counsell said. "But he'll be the first guy cheering you on in the dugout if he's not playing."

NOT THIS TIME

Cole turned in three dominating performances against the Brewers this season until falling victim to the long ball on Wednesday. Cole pitched seven innings and surrendered just one run in each of his previous outings against Milwaukee. Overall, he was 7-0 in his last seven starts on the road. With the no decision on Wednesday, Cole still hasn't lost since May 22 in Atlanta.

"They were able to do damage on the swings that they took," Cole said. "It was unfortunate I couldn't hold them down."

TRAINER'S ROOM

Pirates: C Francisco Cervelli remained out of the lineup. He left Sunday's games with left hand and wrist discomfort. Chris Stewart started in his place.

Brewers: SS Orlando Arcia sat out for the second consecutive game with back spasms. ... C Stephen Vogt (left knee sprain) went 2 for 3 while playing first base for Triple-A Colorado Springs in a game at Iowa. Vogt is expected to make one more rehab start before likely rejoining Milwaukee for a weekend series in Colorado. ... OF Ryan Braun got a routine day off. ... Swarzak pitched in relief for the first time since Aug. 10 after being sidelined with a stiff neck.

UP NEXT

Pirates: Jameson Taillon (7-5) gets the start Thursday as Pittsburgh begins a four-game series at home against St. Louis. Taillon is 0-1 with a 4.91 ERA in three career starts against the Cardinals.

Brewers: Matt Garza (6-6) takes the mound as Milwaukee opens a three-game series at Colorado on Friday. Brandon Woodruff, who had been scheduled to start on Friday, will instead face the Rockies on Saturday.

___

More AP baseball: https://apnews.com/tag/MLBbaseball