I had surgery second (and before IM). A lot of it was medicine, but the test wasn't terrible. Do all of UWorld for surgery (shouldn't be hard, there are only like 200 q's) and UWorld for GI. Read the Pestana notes once early in the rotations and again in the last week (only about 80 pages or so, double spaced). The NMS Casebook is very good. It is pointed and gives a 'if the patient comes in with this, what is the next step' set up which is helpful - read it twice. I read the big NMS textbook, that wasn't particularly high-yield - I wouldn't do it again if I had to do it over. The back of the NMS textbook has a 100 question practice test, it wasn't bad. I also read the Step-Up to Medicine GI, fluids/electrolytes and endocrine chapters early. The Lange practice question book is OK - I did them all - there were some excellent questions, but a bunch of esoteric questions too.
So, in summary
UWorld - Surgery + GI + any other system you're weak in
NMS Casebook (little red book, not thick textbook) - read twice if you have the time
Pestana notes - once early, then again the last couple days
Step Up to Medicine - GI, endocrine, fluids/electrolytes +/- other weak subjects
If you run out of stuff to do: Lange, NMS textbook