Commit 445e48b9 by Michael DeHaan

Call os.path.expanduser in modules so things work as expected even when using…

Call os.path.expanduser in modules so things work as expected even when using ./hacking/test-module script
parent c6b8e162
...@@ -40,8 +40,8 @@ for x in items: ...@@ -40,8 +40,8 @@ for x in items:
(k, v) = x.split("=") (k, v) = x.split("=")
params[k] = v params[k] = v
src = params['src'] src = os.path.expanduser(params['src'])
dest = params['dest'] dest = os.path.expanduser(params['dest'])
# raise an error if there is no src file # raise an error if there is no src file
......
...@@ -88,8 +88,8 @@ for x in items: ...@@ -88,8 +88,8 @@ for x in items:
params[k] = v params[k] = v
state = params.get('state','file') state = params.get('state','file')
path = params.get('path', params.get('dest', params.get('name', None))) path = os.path.expanduser(params.get('path', params.get('dest', params.get('name', None))))
src = params.get('src', None) src = os.path.expanduser(params.get('src', None))
dest = params.get('dest', None) dest = params.get('dest', None)
mode = params.get('mode', None) mode = params.get('mode', None)
owner = params.get('owner', None) owner = params.get('owner', None)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment