remove trailing _ from top-level dirs