TERRY CASHMAN, a lifetime 7-6 pitcher in the minor leagues, knows a hit when he sees one--and when he hears one. Several years ago, during the baseball strike, he came out with a bit of clutch nostalgia, "Talkin' Baseball: Willie, Mickey and the Duke." For writers and broadcasters desperate for something to talk about when nothing was happening, it was Instant News; the song even managed to climb onto the national charts.

On Sunday, before Earl Weaver Appreciation Day at Baltimore's Memorial Stadium, Cashman stood up in front of 41,194 fans, hit the tape deck and belted out "The Earl of Baltimore." It marked his 20th appearance in a major-league stadium singing customized versions of "Talkin' Baseball." "I call myself an arena act now because I only play in front of 40 or 50,000 people," Cashman says lightly.

Custom lyrics have become Cashman's specialty in recent years; in fact, he has written songs about 24 of the 26 major league teams: "Toronto and Seattle the two most recent expansion teams have such short histories that there's no material to draw on and I feel that would be pushing it." And sometime before the end of the month, hard-core fans will have a chance to buy full-length albums featuring all the varied versions; there's one album for the National League and one for the American, with four new songs ("Cooperstown," "Rhubarb," "Baseball Ballet" and "Rain Delay," which is not, as one might expect, a hyperkinetic organ solo).

The songs, set to the same musical track, are pretty much alike: a lot of name-dropping (following the pattern of Dave Frishberg's classic baseball ode, "Van Lingle Mungo") and a little bit of history. Cashman, who played in the Detroit Tiger farm organization many moons ago, is a lifelong fan (his first game was an opening-day no-hitter pitched by Bob Feller against the Yankees in 1946) whose good memory is augmented by the "Baseball Encyclopedia." "I use it to make sure that I'm right historically," Cashman says. He also turns to it to resolve the occasionally difficult rhyme scheme. "That rhyme is the most important thing," Cashman says, "and I try not to put in some really obscure player; the guy has to have some significance. But if I can't find a rhyme someplace and I need somebody and he rhymes . . . well, there have been cases where players got into a song because their names rhymed with somebody else's."

He has also been lucky in that only one song -- about the Detroit Tigers -- has mentioned someone who was subsequently traded (Champ Summers). Cashman, who performed at the Old Timers' Game here several months ago, has taken a bit of razzing from the players, particularly if they feel left out. "I sang one in Chicago and then showed up in Cincinnati and a couple of the guys started laughing and saying 'Do you have one for every team?' "

Before "Talkin' Baseball," Cashman's last recording was in 1975, but in the late '50s he had some chart success as lead singer of the Chevrons (in fact, he was on "American Bandstand" at the same time he was with the Class D Montgomery, Ala., Rebels). He went on to write songs and record with Gene Pistilli and Tommy West (remember "American City Suite"?) and to produce the late Jim Croce's songs. In 1975, Cashman and West formed Lifesong Records, which has had some hits and which will distribute the baseball albums.

Cashman believes the area of sports music is currently untapped, and he is intent on doing the tapping.

And not just in baseball. Cashman already has written a song for the New England Patriots, and for the National Football League in general. "I submitted it to the people at NFL Marketing, but I haven't heard back yet. It was called 'Football: U.S.A.'; I didn't know about the other league [USFL] at the time, so they might want me to change it."

Of course, now that the football players have gone on strike as the baseball players did last year, Cashman could easily revive one of his 1967 hits, originally recorded by Spanky and Our Gang. The prophetic title: "Sunday Will Never Be the Same."