EXCLUSIVE: HBO has given a green light to Crashing, a single-camera comedy pilot directed by comedy mogul Judd Apatow and starring comedian Pete Holmes. Written by Holmes, the semi-autobiographical project centers on a sweet, wholesome comedian (Holmes) who, after his wife leaves him, has nowhere to stay but on the couches of New York’s finest comics. Apatow, Holmes and Holmes’ manager Dave Rath are executive producing the pilot, slated to film in November.

Crashing marks the first pilot directing gig for Apatow, who is in business with HBO as executive producer on Lena Dunham’s comedy series Girls.

Holmes has discussed his experiences being left by his wife in his act as well as on his podcast You Made It Weird where he had mentioned John Mulaney as one of the comedians who’d helped him through his divorce.

Primetime-Panic Your Complete Guide to Pilots and Straight-to-Series orders See All

Apatow, who also is a comedian, has been a guest on Pete’s podcast, and the two also did a skit for Holmes’ late-night show on TBS, which was produced by Conan O’Brien’s Conaco. In it, Holmes pitches Apatow a movie based on the story of his divorce (and life after). “That doesn’t seem like a comedy at all, that seems tragic and sad,” Apatow deadpans.

Holmes goes on to offer his acting services but is turned down. “You can’t be the lead (in a Judd Apatow movie), you can be a friend,” Apatow says. “I don’t say this often, but everyone has to be Jewish, at least the guys, the girls can not be Jewish but the guys have to be Jewish.” Here is the entire exchange:

Apatow is coming off another summer comedy hit, Trainwreck written by and starring comedian Amy Schumer. In TV, where the top comedy filmmaker started his career, he also is executive producing the upcoming Netflix comedy series Love. He is repped by UTA, Mosaic and Ziffren Brittenham. Holmes is with WME and Generate.