Passing command to PS without execution


I wrote a simple batch file to launch PowerShell and change to a particular directory. I have python script that I want to run in that folder. Is there a way of passing the command to PS without running that particular command, from a batch file?

My idea:

  1. Launch PS

  2. cd to directory

  3. Input python "" -params to PS, BUT I don’t want PS to automatically run this line, because depending on what I want to do, there are different arguments that I want to parse to the python script.

Basically, I just want to find a way to have this command written automatically, instead of me having to write it all the time when I run the batch file. Is it something possible?

Thank you.

submitted by /u/Slasher_D
[link] [comments]

Leave a Reply