

def expanduser(self, expr):
    'Expand home shortcuts (e.g., ``~/foo/bar`` or ``~john/foo/bar``)\n\n        :param expr: An expression containing home shortcuts\n\n        :returns: The expanded string'
    prev = os.environ
    os.environ = self.getdict()
    try:
        output = os.path.expanduser(expr)
    finally:
        os.environ = prev
    return output

dataset/ETHPy150Open tomerfiliba/plumbum/plumbum/machines/local.py LocalEnv.expanduser/original