Green’s Dictionary of Slang

shanks’s pony n.

also Mother Shanks’ mare, shank’s, shanks’s mare, ...nag, ...naggy, shank-naggy
[SE shank, a leg + pony/mare/nag/naggie; note synon. US regional ride one’s mother’s colt/granny’s colt/mother’s pony etc.]

[late 18C+] walking, on foot; usu. as ride/take/mount/travel on/go by/go on/use... (see ride shank’s mare under ride v.).