The Binghamton Rumble Ponies scratched out a run in the top of the seventh inning Friday night to pull out a 2-1 victory against the Portland Sea Dogs and earn a split of an Eastern League doubleheader at Hadlock Field.

In the opener, Portland scored its runs in the first inning, and starting pitcher Teddy Stankiewicz and reliever Ty Buttrey made them stand up in a 2-1 win.

The Sea Dogs totaled eight hits for the two seven-inning games.

“We pitched well in both games,” Portland Manager Carlos Febles said.

“Our offense has been cut down, and I think our pitching and defense are playing well together and have been keeping us in games.”

In the opener, the Sea Dogs got all of their hits and scored both of their runs in the first inning. Danny Mars led off with a triple into the gap in right and scored when Chad De La Guerra sliced an opposite-field double down the left-field line. One out later, Jeremy Barfield lined a run-producing single into left.

The score stayed that way until Pat Biondi tripled off the right-field wall to start the sixth and scored on a groundout.

Stankiewicz, who evened his record at 5-5, limited Binghamton to five hits, striking out five and walking one. Buttrey got the final two outs on fly balls to record his fourth save of the season.

In the second game, Binghamton snapped a scoreless tie when Mike Oberste, Peter Alonso and Kevin Taylor singled to open the sixth. The Sea Dogs tied it when Mars walked on four pitches to lead off the bottom of the inning, moved to second on a wild pitch and scored on Josh Tobias’ single to right.

Luis Guillorme led off the seventh with a walk, went to second on Kevin Kaczmarski’s sacrifice, moved to third on a wild pitch and scored on David Thompson’s sacrifice fly to center.

Mike Olt led off the bottom of the seventh with his second double of the game and moved to third when Josh Ockimey flied to deep right, but Tyler Bashlor struck out the next two batters to record his second save since making his Double-A debut July 24.

“You always want to win every games but I’m (more) worried about the process and how you go about your business,” Febles said.

“The guys are in a tough stretch for us, but they’re in every game and are playing real hard.”

NOTES: Following a vote of managers, coaches and the media, Barfield and Mars were named to the Eastern League all-star team. Barfield, a right fielder who has a team-high 23 home runs for the Sea Dogs, is among the league leaders in homers, and Mars, a left fielder who is hitting .303, ranks among the league’s top five in batting average. … Former New York Mets ace Matt Harvey will make his second rehab start for Binghamton on Saturday night against the Sea Dogs. It will be the fourth rehab start for the right-hander, who has been on the disabled list since June 15 after having surgery to repair a stress injury to his right shoulder. On Monday night, Harvey allowed four hits, one of them a home run, in a three-inning stint against the New Hampshire Fisher Cats. … Tobias was held hitless in three trips to the plate in the opener, ending his season-high 10-game hitting steak. … The announced attendance was 6,523.