#NEWLINE# def recursive_listdir( dpath ) : #NEWLINE# #INDENT# listing = [ ] #NEWLINE# for entry in os . listdir ( dpath ) : #NEWLINE# #INDENT# entry_path = os . path . join ( dpath , entry ) #NEWLINE# if os . path . isdir ( entry_path ) : #NEWLINE# #INDENT# listing . append ( recursive_listdir ( entry_path ) ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# listing . append ( dpath ) #NEWLINE# #UNINDENT# #UNINDENT# return listing