[users at bb.net] Killing a windows task(process) using taskkill from the shellcommand

Dan Kegel dank at kegel.com
Fri Apr 1 15:57:25 UTC 2016


FWIW, I invoke a script for my build steps, and it has the line
taskkill /F /IM mspdbsrv.exe /T
in it.  Works great.   While it may seem strange to put
the build logic in a script (or batch file) rather than in build steps,
it sure makes debugging easier.

On Fri, Apr 1, 2016 at 8:28 AM, honas grael <honasgraeymael at gmail.com> wrote:
> Hi Everyone,
>
> I don't know if i'm doing it worng but I have an executable task that I want
> to kill at the end of my build.
>
> It seems easy enough to start the executable using something along the lines
> of
>
> factory.addStep(steps.ShellCommand(
>
> command=["run_my_custom_executable.exe","config_file_for_executable.txt"],
>               logfiles={"triallog": {"filename": "c:\\temp\\test.log",
>                    HaltOnFailure=True))
>
> I want to kill that executable, so I have tried
>
> factory.addStep(steps.ShellCommand(command=["cmd /c taskkill /im
> run_my_custom_executable.exe /f /t]))
>
> but no joy so far, though the command works fine when I type it directly
> into the Windows command shell.
>
>
> Also I wanted to introduce a time delay between steps so I thought I'd use
> the Windows timeout shell command
>
>
> factory.addStep(steps.ShellCommand(command=["cmd /k timeout 30 /nobreak]))
>
> What am i missing?
>
>
>
> Regards
>
>
>
>
> _______________________________________________
> users mailing list
> users at buildbot.net
> https://lists.buildbot.net/mailman/listinfo/users


More information about the users mailing list