def _exclude_home(path_list):
 home = os.path.expanduser('~')
 for p in path_list:
  if (not p.startswith(home)):
   (yield p)

def _exclude_home ( path_list ) : home = os . path . expanduser ( '~' ) for p in path_list : if ( not p . startswith ( home ) ) : ( yield p )
filter out any entries in a path list that are in my home directory .