|
@@ -180,12 +180,15 @@ class StdoutTee:
|
|
|
|
|
|
@contextlib.contextmanager
|
|
|
def chdir(path):
|
|
|
+ import shlex
|
|
|
previous = os.getcwd()
|
|
|
try:
|
|
|
+ sys.stderr.write('cd {}\n'.format(shlex.quote(path)))
|
|
|
os.chdir(path)
|
|
|
yield path
|
|
|
finally:
|
|
|
os.chdir(previous)
|
|
|
+ sys.stderr.write('cd {}\n'.format(shlex.quote(previous)))
|
|
|
|
|
|
def dpkg_listfiles(pkg_name):
|
|
|
assert isinstance(pkg_name, str)
|