Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Debugging a script should dot-source it into the session #540

Closed
daviwil opened this issue Mar 15, 2017 · 1 comment
Closed

Debugging a script should dot-source it into the session #540

daviwil opened this issue Mar 15, 2017 · 1 comment
Labels
Issue-Enhancement A feature request (enhancement).
Milestone

Comments

@daviwil
Copy link
Contributor

daviwil commented Mar 15, 2017

ISE parity request: when launching a script in the debugger, it should be dot-sourced so that its contents become available in the console session after the script finishes executing.

Question: should this be configurable even if I provide a separate option to always create a new PowerShell session each time the debugger starts?

/cc @dfinke @dotps1

@daviwil daviwil added the Issue-Enhancement A feature request (enhancement). label Mar 15, 2017
@daviwil daviwil modified the milestones: 0.10.1, 0.11.0 Mar 15, 2017
@daviwil
Copy link
Contributor Author

daviwil commented Mar 15, 2017

Looked into this briefly, seems that the missing piece is that I need to pass an additional parameter to PSCommand.AddScript, a boolean that causes the script to be evaluated into the local scope:

https://msdn.microsoft.com/en-us/library/dd182484(v=vs.85).aspx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Enhancement A feature request (enhancement).
Projects
None yet
Development

No branches or pull requests

1 participant