Sherman spent the (Mexican) war stationed in San Francisco, which in fact, was one of the factors that led to his dissatisfaction with the Army prompting him to resign and go into banking. He was there at the very onset of the gold rush and had occaision to meet John Sutter (of Sutter's mill fame).
Thanks, Joe!