def remove_dirs(basedir, dirs):
"""Starting at join(basedir, dirs), remove the directory if empty,
and try the same with its parent, until we find a nonempty
def remove_dirs(basedir, dirs):
"""Starting at join(basedir, dirs), remove the directory if empty,
and try the same with its parent, until we find a nonempty