I'm trying to run a command that uses a variable as the executable. In Cmd, I would just do the following:
%MY_PROGRAM% -my_program_option
I'm trying to do the same in PowerShell doing this, but it always launches in a new command (not PowerShell) terminal:
Invoke-Expression "${MY_PROGRAM} -my_program_option"
How can I make it launch in the current PowerShell terminal session?