I hate fruit flies. Not so much because of the actual insect but more because an infestation feels like a hygienic failure of the worst kind. I take it personally. People judge, I know they will judge, and I don't need to carry around any more baggage let alone worry.
I am certain I have seen them hatch off a clean countertop like a gazillion evening mayflies on a trout stream. They are every cook's summer nemesis and if things go badly, or in the fruit flies' favor, the fruit fly season will carry over into fall. Fruit flies are insidious.
Early in the season, I place a bowl of vinegar (rice, apple, or red wine seem to work best) with a splash of dish soap under a larger glass bowl that rests on chopsticks and I set it at the back of the sink 24-7. The flies go in and they can't come out. (Editor's note: We compared this to our beloved plastic wrap method, and found we caught more fruit flies this way.)
Midseason, when the fruit fly population can explode, I set a small bowl of vinegar in the top rack of the dishwasher. I leave the door cracked open overnight and in the morning I sneak up on it and slam it shut, turn it on, and wash those fruit flies down the drain.
God forbid it's a really bad infestation, but if it is, I set a vinegar-soaked towel in the laundry room sink. Come morning I creep in with an aerosol can of flying insect killer and spray a small cloud of toxic gas across the top of the sink. (No need to go into any further detail other than it's deadly for the fruit flies.)
May your summer be fruit fly free.