trimming unneeded files