6 Oct
2012
6 Oct
'12
6:35 a.m.
How about making a path object behave like a sequence of pathname components? Then * You can iterate over it directly instead of needing .parents() * p[:-1] gives you the dirname * p[-1] gives you the os.path.basename -- Greg