Rearrange directory hierarchy