refactor dir listing
pep8