Ninteen years ago on May 31, 1988 the Yankees were playing the Oakland A's.
Al Leiter of the Yanks started the game, but had to leave with an injury after leadoff batter Carney Lansford singled on the only pitch he threw. Neil Allen came in and pitched 9 innings of 3 hit relief in a 5-0 Yankee victory.
Under rule 10.19 (f), that qualified him to be credited with a shutout."
Allen finished the year with 2 starts, 0 CG, and 1 shutout.
Here's rule 10.19 (f) from Baseball-Almanac.com:
"No pitcher shall be credited with pitching a shutout unless he pitches the complete game, or unless he enters the game with none out before the opposing team has scored in the first inning, puts out the side without a run scoring and pitches all the rest of the game. When two or more pitchers combine to pitch a shutout a notation to that effect should be included in the league's official pitching records."