I just did this exact thing for my compressor 2 weeks ago.
I cut my wall open (approx. 4 inches by 18 feet) and ran 8-2 NM-B in the wall studs. I used a 40 amp double pole breaker and the same Square D disconnect pattenp linked to above.
While I already had the wall open I added 3 more 120v...