• Kills the process that calls the method and all its children.

    Parameters

    • pid: string | number = process.pid

      Pid of the process to kill.

    • killSignal: string = 'SIGTERM'

      Type of kill signal to be used.

    • killRoot: boolean = true

      Whether to kill the root process.

    • Optional callback: AfterKillCallback

      Optional callback to run after killing the processes.

    Returns void