Avoid spawning console windows when running from .pyw by boppreh · Pull Request #126 · gitpython-developers/GitPython (original) (raw)

I'm developing a small background application (Windows + PyQt) to track Git repositories.

The GitPython module works great, but when called from a windowless script (.pyw) each command spawns a console window. Those windows are empty and last only a second, but I think they should not be there at all.

I saw it was using Popen to call the git executable and added a shell=True parameter to avoid spawning those windows.

Be aware I haven't tested this on other machines or operating systems.