rearrange for directories and a few cleaning works