Houston Astros' Jed Lowrie, right, is greeted by Colby Rasmus after hitting a home run off San Francisco Giants relief pitcher George Kontos during the eighth inning of a baseball game Wednesday, Aug. 12, 2015, in San Francisco. Houston won 2-0. (AP Photo
Eric Risberg
August 12, 2015

SAN FRANCISCO (AP) Houston's lighted spinning disco ball was back in the clubhouse, and so was the fog machine.

The two staples of celebration for the AL West-leading Houston Astros didn't get much use during the team's longest road trip since the All-Star break. Both were in full effect Wednesday after manager A.J. Hinch's ballclub ended its four-game losing streak.

Colby Rasmus homered to lead off the seventh inning to help Scott Feldman earn his first win in more than two months, and Houston held on to beat the San Francisco Giants 2-0.

Jed Lowrie also homered for the Astros, who stumble back to Minute Maid Park with a slimmer division lead after going 2-7 on their nine-game road trip.

''It was nice to squeeze one out of here,'' Hinch said. ''It's never easy in this park. It hasn't been easy for us on this trip. To be able to shake hands afterward was a good feeling. We needed it.''

Feldman (5-5) missed 45 games earlier this season with a torn meniscus and had been winless in four starts since coming off the disabled list in July. He combined with four relievers on the five-hit shutout.

The Astros right-hander - winless since May 26 - gave up four hits over six innings, walked one and struck out four while allowing only one runner past second base.

''I felt good,'' Feldman said. ''I don't face these guys too often so I just tried to remember some of the guys that I had faced in the past and just get on the same page with (catcher Jason Castro). I had a pretty good command of all four pitches and that was kind of helpful.''

Luke Gregerson pitched the ninth for his 23rd save.

The slumping Astros needed it on a day they managed only five hits.

Giants starter Chris Heston (11-7) allowed one run and over 6 1-3 innings. The San Francisco rookie struck out four and matched his season high with four walks while losing consecutive starts for the first time.

Rasmus ended the pitcher's duel with his 15th home run of the season, a solo shot that bounced into McCovey Cove over the right field wall.

Lowrie homered with two outs in the eighth off George Kontos.

Feldman retired 12 of 14 during one stretch, getting help from shortstop Carlos Correa, who made a running, bobbling catch on Nori Aoki's high fly to short center.

''Their guy pitched well . but we didn't generate any offense,'' Giants manager Bruce Bochy said. ''We just couldn't get much going offensively.''

FELDMAN MUSCLES UP A SINGLE: The Astros had three singles in the game, including Feldman's first hit of the season. The Houston pitcher struck out in his first at-bat against Heston before blooping a single to left with two outs in the fifth. It was Feldman's first hit since June 15, 2013, when he was pitching full-time in the National League with the Chicago Cubs.

''I used to like to hit,'' Feldman said. ''Now it's just try not to embarrass yourself and see if you can maybe close your eyes and get lucky. It's always fun playing in the National League and playing at this ballpark for me especially.''

TRAINER'S ROOM

Astros: OF Carlos Gomez was held out of the game after injuring his right knee while colliding with the fence in the first inning of Tuesday's loss. Gomez flew out as a pinch hitter in the seventh.

Giants: Aoki was back in the lineup after getting hit in the head by a pitch from the Cubs' Jake Arrieta on Sunday but was dizzy afterward and will be re-evaluated on Thursday. .... RHP Mike Leake is eligible to come off the disabled list Aug. 18. He's expected to be activated and slide back into the rotation.

UP NEXT

Astros: LHP Dallas Keuchel (13-6) pitches against Detroit on Friday when Houston begins a 10-game homestand. Keuchel was beaten in his previous outing and has not lost consecutive starts this season.

Giants: RHP Ryan Vogelsong (7-8) makes his second start in place of Leake when the Giants begin a four-game series at home against Washington on Thursday.

You May Like