noseglid / atom-build

:hammer: Build your project directly from the Atom editor
https://atom.io/packages/build
MIT License
248 stars 97 forks source link

Having trouble starting multiple exes on windows #524

Closed Saucistophe closed 6 years ago

Saucistophe commented 7 years ago

There might be something I'm doing wrong, but hey, I've tried everything.

I want my command to start several background exes, keep them open, and finish the build. That way, I can start the exes, modify js files and test away.

To do that, no problem, I call a bat that STARTs all my exes: .atom-build.json:

"targets": {
        "start-exes":
        {
            "cmd": "start go.bat",
            "cwd": "{PROJECT_PATH}"
        }
    }

go.bat:

start app1.exe
start app2.exe

I've tried every possible way. Starting the bat, CALLing it, adding /C flag, same in the bat file, whatever.

Any way, the result is the same: The build keeps running until I've closed every single background application; making it unusable for other targets.

My assumption is that every way proposed by windows commands will spawn other exes, but considered as children of the root process, which will not die until they all die, and will not mark the build as finished until then.

Is there a way to do so? I would like it very very much. Thank you!

noseglid commented 6 years ago

You need to detach the process. I can't help you with that and it's outside the scope of this project.