Michał Górny  committed 5af8731

Handle package.* directories recursively.

It seems that portage actually supports having directories in package.*
directories recursively. Use os.walk() to accomodate that properly.


  • Participants
  • Parent commits 7e9098a

Comments (0)

Files changed (1)

File lib/flaggie/

 		for fn in self._paths:
 			if os.path.isdir(fn):
-				files = [os.path.join(fn, x) \
-						for x in os.listdir(fn) \
-						if not x.startswith('.') and not x.endswith('~')]
+				files = []
+				for toppath, wdirs, wfiles in os.walk(fn):
+					for f in wfiles:
+						if f.startswith('.') or f.endswith('~'):
+							continue
+						files.append(os.path.join(toppath, f))
 				if not files:
 					files = [os.path.join(fn, 'flaggie')]