After a series of maneuvers, Jackson defeated Frémont's command at Cross Keys and Brig. Gen. James Shields at Port Republic on June 8–9. Union forces were withdrawn from the Valley.