SAN FRANCISCO — Nobody was warming up in the bullpen.

David Price had just escaped a 29-pitch seventh, an inning in which he lost his momentum and showed his first signs of fatigue. It took him 10 pitches to retire Giants backup catcher Trevor Brown. He needed eight to get past reserve outfielder Jarrett Parker.

But manager John Farrell showed nothing but full confidence in Price, sending him to the mound in the eighth on 97 pitches with nobody up in the bullpen. If the Red Sox were going to lose to one of the best teams in the National League, Farrell wanted to go down with his best pitcher on the mound.

The first pitch Price threw to start the eighth was an 84-mph cutter to Mac Williamson, who skied it high over the left field wall for his first major league home run. It was a decisive blow in the Giants’ 2-1 win at AT&T Park.

Williamson’s first two at-bats against Price ended in strikeouts. One was on an 87-mph cutter and the other was an 89-mph cutter. Williamson must’ve caught on.

Farrell felt confident in his decision to leave Price in the game to start the eighth.

“The way he had handled Williamson, the way he handled the bottom of the order, they're left-handed all the way through to the top of the order and I didn't see a major dropoff,” Farrell said. “With 97 pitches through seven, I thought he was in pretty good shape. The cutter didn't get to the spot for the ball that hits off the top of the wall.”

Price said his pitch to Williamson just missed.

He had already outlasted Giants ace Madison Bumgarner in a matchup of two of the best left-handers in the game. Both allowed solo homers in the fourth. First it was Bumgarner, who served up a bomb to Chris Young. Then Price left a hanging curve to Brandon Belt, who turned that one into fish food as he hammered it into McCovey Cove.

Through six innings, the game was tied 1-1. Price had mowed down the Giants on just 68 pitches. Red Sox hitters had grinded through at-bats against Bumgarner, who had thrown 101 pitches.

Bumgarner’s night was done, but Price jogged out for the seventh.

With the middle of the order up for the Giants, Price labored through the inning, needing at least five pitches against all four batters he faced and 29 overall.

In the eighth, Williamson beat him.

Asked if he was gassed after the long seventh, Price said, “No, I don't think so. That was the first pitch right there. Battled back and got the next three guys out. It was one pitch.”

Williamson nearly gave the game back to the Red Sox in the ninth inning, when he dropped a fly ball in the left-center field gap and put Hanley Ramirez on second base with nobody out.

But Jackie Bradley Jr. struck out looking. David Ortiz, pinch-hitting for Chris Young, drew a hard-earned walk against lefty Javier Lopez, but Lopez struck out Travis Shaw.

The Giants finally turned to right-hander Hunter Strickland to end the game against Christian Vazquez, who was lifted for the left-handed hitting Marco Hernandez. Hernandez grounded out on the first pitch.

Price said he picked up some momentum after his first complete game of the season.

“It's actually probably my best outing of the year,” said Price, who lowered his ERA to 4.62. “It's good. Continue to build on what I've done in the past month of my starts and going to continue winning baseball games.”