lowleveldesign / process-governor

This application allows you to put various limits on Windows processes.
MIT License
626 stars 62 forks source link

Need to be able to pass in CLI options #39

Closed linuxgurugamer closed 2 years ago

linuxgurugamer commented 2 years ago

I am trying to use this with a Unity game which is having some issues with memory. I need to be able to pass in some options on the command line, but there doesn't seem to have a way to do that.

For example, the CLI I'm trying to run is:

C:\local\ProcessGoverner\procgov64.exe -m 32G KSP_x64.exe -single-instance -popupwindow -adapter 0

I tried putting quotes around the CLI parmeters for the program, and they were ignored: C:\local\ProcessGoverner\procgov64.exe -m 32G KSP_x64.exe "-single-instance -popupwindow -adapter 0"

I was able to attach using the pid, but that's awkward to do every time.

lowleveldesign commented 2 years ago

Thanks for reporting, it's definitely a bug. Procgov tries to parse the -popupwindow option. I will try to fix it this week.

lowleveldesign commented 2 years ago

After checking again, it looks that the following should work:

C:\local\ProcessGoverner\procgov64.exe -m 32G -- KSP_x64.exe -single-instance -popupwindow -adapter 0

Please try it and let me know if it fixes the problem.

linuxgurugamer commented 2 years ago

Yes it does, thank you.

Might I suggest that you add something to the README about it?

Greatly appreciate your quick response

lowleveldesign commented 2 years ago

README updated.

linuxgurugamer commented 2 years ago

Amazing!!!