From c5b381c3af851468406f8ee71cbf24b5f11becdf Mon Sep 17 00:00:00 2001 From: "Yaakov M. Nemoy" Date: Fri, 16 Jan 2009 21:26:10 -0500 Subject: Small bugfixes --- base/util.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'base') diff --git a/base/util.py b/base/util.py index 5f71534..5193bcd 100644 --- a/base/util.py +++ b/base/util.py @@ -108,5 +108,9 @@ def flatten(l): _flatten(acc, l) return acc +def base_dir(tarball): + ti = tarball.next() + return ti.name.split('/')[0] + __all__ = ['pwd', 'copy', 'with_sudo', 'with_su', 'symlink', 'move', - 'log_file', 'one', 'remove_all', 'flatten'] + 'log_file', 'one', 'remove_all', 'flatten', 'base_dir'] -- cgit