Umm, I'd say "some bugs", but not most.

Yep, that's how cedar closets in older homes work- cedar repels, in particular, moths.