Skip to content

Commit 4b5c73a

Browse files
authored
Merge pull request #127 from python-cmd2/pyscript_expanded_path
pyscript now expands the script path before calling do_py
2 parents a8c6434 + c0245f3 commit 4b5c73a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cmd2.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1611,7 +1611,7 @@ def do_pyscript(self, arg, opts=None):
16111611
sys.argv.extend(arg[1:])
16121612

16131613
# Run the script
1614-
self.do_py("run('{}')".format(arg[0]))
1614+
self.do_py("run('{}')".format(script_path))
16151615

16161616
# Restore command line arguments to original state
16171617
sys.argv = orig_args

0 commit comments

Comments
 (0)